Package ai.djl.training.tracker
Class CosineTracker.Builder
java.lang.Object
ai.djl.training.tracker.CosineTracker.Builder
- Enclosing class:
- CosineTracker
The Builder to construct an
CosineTracker
object.-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds aCosineTracker
block.optFinalValue
(float finalValue) Sets the final value that the learning rate will remain constant as after the specified max number of updates.setBaseValue
(float baseValue) Sets the initial value after no steps.setMaxUpdates
(int maxUpdates) Sets the maximum number of updates after which the value should remain constant.
-
Method Details
-
setBaseValue
Sets the initial value after no steps.- Parameters:
baseValue
- the initial value- Returns:
- this
Builder
-
optFinalValue
Sets the final value that the learning rate will remain constant as after the specified max number of updates.- Parameters:
finalValue
- the final value- Returns:
- this
Builder
-
setMaxUpdates
Sets the maximum number of updates after which the value should remain constant.- Parameters:
maxUpdates
- the maximum number of updates after which the value should remain constant- Returns:
- this
Builder
-
build
Builds aCosineTracker
block.- Returns:
- the
CosineTracker
block
-