ENSTA-U2IS-AI / torch-uncertainty

Open-source framework for uncertainty and deep learning models in PyTorch :seedling:
https://torch-uncertainty.github.io
Apache License 2.0
223 stars 16 forks source link

:bug: Calibration plot error #61

Closed o-laurent closed 8 months ago

o-laurent commented 8 months ago

In one of my latest training, I had the following error in plotting_utils.py, line 95:

val_oh = torch.nn.functional.one_hot(val.long(), num_classes=10)
RuntimeError: Class values must be non-negative.

I don't have much more information about this, but we should check if some cases lead to such an error.