Closed FrankWJW closed 2 years ago
Simply, you can modify the model to use nn.CrossEntropyLoss. However, supporting diverse loss functions is quite interesting. Actually, torchattacks.UPGD supports three different loss options. Thank you for your suggestion.
I try a multi-label classification problem with![image](https://user-images.githubusercontent.com/25313385/164341255-96f2f69d-c100-4b5b-b98c-f498a60aacb1.png)
torchattacks.FGSM(net, eps=0.1)
I don't know if this make sense, but considering adding support for different type of loss function such as
nn.BCEWithLogitsLoss()
may be good?