Closed jmoralez closed 5 months ago
The logic here https://github.com/Nixtla/neuralforecast/blob/9e0efab6a6507b0d10e67f2d668dac7c58dec1ab/neuralforecast/common/_base_multivariate.py#L124-L129 only added the early stopping callback if there weren't any callbacks already set. This made it so that it was never enabled for auto models that used ray, since we add the TuneReportCallback https://github.com/Nixtla/neuralforecast/blob/9e0efab6a6507b0d10e67f2d668dac7c58dec1ab/neuralforecast/common/_base_auto.py#L196
TuneReportCallback
This fixes that check by building an empty list of callbacks if there aren't any and always appending EarlyStopping to the existing callbacks. Also moves some duplicated logic in the init signature of the base classes to the base model.
EarlyStopping
Check out this pull request on
See visual diffs & provide feedback on Jupyter Notebooks.
Powered by ReviewNB
The logic here https://github.com/Nixtla/neuralforecast/blob/9e0efab6a6507b0d10e67f2d668dac7c58dec1ab/neuralforecast/common/_base_multivariate.py#L124-L129 only added the early stopping callback if there weren't any callbacks already set. This made it so that it was never enabled for auto models that used ray, since we add the
TuneReportCallback
https://github.com/Nixtla/neuralforecast/blob/9e0efab6a6507b0d10e67f2d668dac7c58dec1ab/neuralforecast/common/_base_auto.py#L196This fixes that check by building an empty list of callbacks if there aren't any and always appending
EarlyStopping
to the existing callbacks. Also moves some duplicated logic in the init signature of the base classes to the base model.