https://github.com/nixtla logo
#neural-forecast
Title
# neural-forecast
s

Stefan Wiegand

08/11/2023, 1:53 PM
Hi, is there a way to visualize the convergence of a model i.e. plot the loss per training step after or during training?
👀 1
c

Cristian (Nixtla)

08/12/2023, 3:23 PM
Hi @Stefan Wiegand. You can manually plot them using the stored trajectories. We store the train and validation losses of each training step in the
train_trajectories
and
valid_trajectories
objects. You can access them like
nf.models[0].train_trajectories
after the model is trained
👍 2
Alternatively, you can use tools like TensorBoard
s

Stefan Wiegand

08/14/2023, 7:20 AM
Great, thanks for your explanation, that’s exactly what I need!
Just for the future reader, when using an AutoNHITS model the trajectories are here: nf.models[0].model.train_trajectories
f

Farzad E

09/10/2023, 1:16 PM
As Cristian mentioned TensorBoard is a good option and if you happen to use VSCode it is now integrated with TensorBoard. All models do automatic logging so for anyone interested all you need to do when running your models is to search TensorBoard in VSCode and open it in another tab and watch the loss functions updating in realtime.