Skip to content

How to “lightninfy” the official PyTorch sentiment analysis tutorial? #6226

Discussion options

You must be logged in to vote

@davidefiocco Hi, I think you're trying to instantiate the criterion class with output and cls. You need to instantiate it in advance:

-        self.criterion = criterion
+        self.criterion = criterion()

Replies: 1 comment 1 reply

Comment options

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

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