pycmtensor.scheduler
Contents
pycmtensor.scheduler#
PyCMTensor scheduler module
Module Contents#
- class pycmtensor.scheduler.Scheduler[source]#
Base class for Scheduler object
Constructor for Scheduler class object
- class pycmtensor.scheduler.ConstantLR(lr=0.01)[source]#
Bases:
SchedulerBase class for constant learning rate scheduler
Constructor for ConstantLR class object
- Parameters
lr (float, optional) – learning rate value
- class pycmtensor.scheduler.StepLR(lr=0.01, factor=0.25, drop_every=10)[source]#
Bases:
ConstantLRBase class for step learning rate scheduler
Constructor for StepLR class object
- Parameters
lr (float) – initial learning rate value
factor (float, optional) – percentage reduction to the learning rate
drop_every (int, optional) – step down the learning rate after every n steps
- class pycmtensor.scheduler.PolynomialLR(max_steps, lr=0.01, power=1.0)[source]#
Bases:
ConstantLRBase class for polynomial decay learning rate scheduler
Constructor for PolynomialLR class object
- Parameters
lr (float) – initial learning rate value
max_steps (int) – the max number of training steps to take
power (float, optional) – the exponential factor to decay
- class pycmtensor.scheduler.CyclicLR(lr=0.01, max_lr=0.1, cycle_steps=16, scale_fn=None)[source]#
Bases:
ConstantLRBase class for cyclical learning rate scheduler
Constructor for ConstantLR class object
- Parameters
lr (float, optional) – the base learning rate value
max_lr (float, optional) – the maximum learning rate value
cycle_steps (int, optional) – the number of steps to complete a cycle
scale_fn (func, optional) – custom scaling policy defined by a single arg
- class pycmtensor.scheduler.Triangular2CLR(lr=0.01, max_lr=0.1, cycle_steps=16)[source]#
Bases:
CyclicLRClass object for the Triangular2 Cyclic LR scheduler
Constructor for Triangular2CLR class object
- Parameters
lr (float, optional) – the base learning rate value
max_lr (float, optional) – the maximum learning rate value
cycle_steps (int, optional) – the number of steps to complete a cycle
- class pycmtensor.scheduler.ExpRangeCLR(lr=0.01, max_lr=0.1, cycle_steps=16, gamma=0.5)[source]#
Bases:
CyclicLRClass object for the exponential range Cyclic LR scheduler
Constructor for Triangular2CLR class object
- Parameters
lr (float, optional) – the base learning rate value
max_lr (float, optional) – the maximum learning rate value
cycle_steps (int, optional) – the number of steps to complete a cycle