-
Notifications
You must be signed in to change notification settings - Fork 55
Open
Description
Hi there!
I've been looking at your training loop in the text classification tutorial and I see that you calculate a total running loss before averaging to get the average loss after the loop ends.
Looking at this line though I'm a little confused
running_loss += loss.data[0] * x.size(0)
When I print out the shape of x
I get these values
The batch sizes appear to be at index 1 so should the running loss line read running_loss += loss.data[0] * x.size(1)
?
Entirely possible that I've made the mistake here but thought I would ask anyway!
Metadata
Metadata
Assignees
Labels
No labels