Skip to content

LabelEncodeIntegerGraded in Multi-instance tutorial #1488

Answered by relyativist
relyativist asked this question in Q&A
Discussion options

You must be logged in to vote

@KumoLiu Thank for your reply, and apologize for a long answer. I haven't seen up-to-index label encoding, before. It still a challenge to understand why you used BCELossWithLogits? Since you are solving multi-class classification problem, the model should assign maximum probability to one class. From you example, criterion is applied on output of the linear layer, sigmoid() inside the BCE loss is applied to each of the values in linear tensor, so we can have multiple values with high logits values. Seems, that this loss is tries to solve multi-label classification rather than multi-class problem.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@relyativist
Comment options

Answer selected by relyativist
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants