Pannaga S
07/06/2025, 11:36 AMnf = NeuralForecast(
models=self.models,
freq=self.freq
)
Here, self.models is a list of AutoModel instances. When I then run nf.fit(df=train_df)
, all the models train in sequence. Since I'm using around 10 models, it is a bit difficult to track which model is being trained. So, I was wondering if there was a way to log/print the model that is being trained.
I understand that I can just run my own for loop for model training and prediction, however, I was just wondering if there was a native way to do this. Thanks!Jing Qiang Goh
07/06/2025, 12:32 PMAsk Inkeep
07/06/2025, 12:32 PMAsk Inkeep
07/06/2025, 12:32 PMNeuralForecast
class with multiple AutoModels (1) (2) .
The NeuralForecast
class processes the models sequentially when you call the fit
method, but the documentation doesn't show any parameters or methods to enable model-specific logging during training (2) (3) .
For tracking which AutoModel is currently training, you would need to implement your own logging solution by training the models individually in a loop rather than passing them all to the NeuralForecast
class at once.
The AutoModels like AutoNHITS
, AutoLSTM
, etc. do support a verbose
parameter that can be set to True
to track progress, but this controls the hyperparameter optimization progress within each individual model rather than indicating which model in your collection is being trained (4) (3) .
model = AutoNHITS(h=12, verbose=True)
(4)
If you need to track which model is training, implementing your own training loop would be the most straightforward approach.Ask Inkeep
07/06/2025, 12:32 PM