How can i plot loss funstions in my main script?

i have a plotting.py script located in my auxiliary folder. two loss function defined in it as follows:

i want to use them to plot my losses in results and use them in my main script:
how can i do that?
for example the code used this method below to plot plot_example_augmentations function:
plotting.plot_example_augmentations(moving_image, fixed_image, os.path.join(path_saving, ‘augmentations_example_img.png’))

You should consider checking out TensorBoard. In my opinion it’s the best way to plot loss values in realtime. https://youtu.be/VJW9wU-1n18?si=b1J4erhsmCsGgvtG

1 Like

Another great option is using Weight and Biases. It is really easy and quick to track your metrics and create reports aswell.

1 Like