EngineBuilder.add_adaptation()#
- EngineBuilder.add_adaptation(duration, init=0.1, term=0.2, base=25, thinning=1)[source]#
Adds adaptation epochs, for tuning kernel hyperparameters.
This follows the Stan Development Team (Stan Reference Manual 2021, Chapter 15.2 [1]).
Note that the order in which you add epochs matters. Adaptation epochs should usually come before all other epochs.
- Parameters:
duration (
int) – The number of adaptation samples.init (
float|int) – The share of samples in the initial fast adaptation epoch, relative to the total number of adaptation samples (if given as a float), or the total number of init samples (if given as an integer). (default:0.1)term (
float|int) – The share of samples in the final fast adaptation epoch, relative to the total number of adaptation samples (if given as a float), or the total number of term samples (if given as an integer). (default:0.2)base (
int) – The number of samples in the first slow adaptation epoch. (default:25)thinning (
int) – Thinning applied in each adaptation. (default:1)
Warning
Kernels which rely on history tuning might not be able to deal with thinning during adaptation.
References