How to correct use loss function from Pytorch

How to properly use focal_loss from Pytorch with the Hugging face trainer?
A multi-class audio classification task with the hubert model

https://pytorch.org/vision/main/_modules/torchvision/ops/focal_loss.html

1 Like