ExponentialAccept
- class pyoptex.analysis.estimators.sams.accept.ExponentialAccept(T0=1, rho=0.95, kappa=4)[source]
Compute the temperature of the Simulated Annealing system according to an exponential.
Updates the temperature with T = T * rho if the model got accepted.
Updates the temperature with T = T / alpha if the model got rejected. alpha = rho ** (1/kappa).
Attributes
- T0float
The initial temperature of the system.
- rhofloat
The reduction factor when the new state is accepted. Should be less than 1.
- alphafloat
The increase factor when the new state is rejected. Computed as \(\rho^{1/\kappa}\).
- __init__(T0=1, rho=0.95, kappa=4)[source]
Create the acceptance function.
Parameters
- T0float
The initial temperature
- rhofloat
The reduction factor when a state is accepted.
- kappafloat
The exponential factor when computing alpha, the increase factor when a state is rejected. When accepting a state and rejecting kappa states, the temperature will remain constant.
Methods
Computes the exponential probability
Called when the state got accepted.
Called when the state got rejected.
Resets the temperature to its original T0 value.