(self, bracket_id: int)
return math.ceil(self._n_brackets * (self._reduction_factor ** s) / (s + 1))
Compute the trial allocated budget for a bracket of ``bracket_id``.

        In the `original paper <http://www.jmlr.org/papers/volume18/16-558/16-558.pdf>`, the
        number of trials per one bracket is referred as ``n`` in Algorithm 1. Since we do not know
        the total number of trials in the leaning scheme of Optuna, we calculate the ratio of the
        number of trials here instead.
Compute the trial allocated budget for a bracket of ``bracket_id``.
Compute the trial allocated budget for a bracket of bracket_id .
def _calculate_trial_allocation_budget(self, bracket_id: int) -> int:
        """Compute the trial allocated budget for a bracket of ``bracket_id``.

        In the `original paper <http://www.jmlr.org/papers/volume18/16-558/16-558.pdf>`, the
        number of trials per one bracket is referred as ``n`` in Algorithm 1. Since we do not know
        the total number of trials in the leaning scheme of Optuna, we calculate the ratio of the
        number of trials here instead.
        """

        assert self._n_brackets is not None
        s = self._n_brackets - 1 - bracket_id
        return math.ceil(self._n_brackets * (self._reduction_factor ** s) / (s + 1))
def _calculate_trial_allocation_budget ( self , bracket_id : int ) -> int : assert self . _n_brackets is not None s = self . _n_brackets - 1 - bracket_id return math . ceil ( self . _n_brackets * ( self . _reduction_factor ** s ) / ( s + 1 ) )