Medial Code Documentation
Loading...
Searching...
No Matches
Public Member Functions | Data Fields
xgboost.callback.LearningRateScheduler Class Reference
Inheritance diagram for xgboost.callback.LearningRateScheduler:
xgboost.callback.TrainingCallback

Public Member Functions

None __init__ (self, Union[Callable[[int], float], Sequence[float]] learning_rates)
 
bool after_iteration (self, _Model model, int epoch, TrainingCallback.EvalsLog evals_log)
 
- Public Member Functions inherited from xgboost.callback.TrainingCallback
_Model before_training (self, _Model model)
 
_Model after_training (self, _Model model)
 
bool before_iteration (self, _Model model, int epoch, EvalsLog evals_log)
 

Data Fields

 learning_rates
 

Additional Inherited Members

- Static Public Attributes inherited from xgboost.callback.TrainingCallback
 EvalsLog = Dict[str, Dict[str, _ScoreList]]
 

Detailed Description

Callback function for scheduling learning rate.

.. versionadded:: 1.3.0

Parameters
----------

learning_rates :
    If it's a callable object, then it should accept an integer parameter
    `epoch` and returns the corresponding learning rate.  Otherwise it
    should be a sequence like list or tuple with the same size of boosting
    rounds.

Constructor & Destructor Documentation

◆ __init__()

None xgboost.callback.LearningRateScheduler.__init__ (   self,
Union[Callable[[int], float], Sequence[float]]   learning_rates 
)

Reimplemented from xgboost.callback.TrainingCallback.

Member Function Documentation

◆ after_iteration()

bool xgboost.callback.LearningRateScheduler.after_iteration (   self,
_Model  model,
int  epoch,
TrainingCallback.EvalsLog   evals_log 
)
Run after each iteration.  Return True when training should stop.

Reimplemented from xgboost.callback.TrainingCallback.


The documentation for this class was generated from the following file: