Skip to content

Commit

Permalink
Remove for double usage of log_softmax (pytorch#721)
Browse files Browse the repository at this point in the history
  • Loading branch information
soumith authored Mar 5, 2020
1 parent e9e7672 commit 1800513
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion word_language_model/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ def batchify(data, bsz):
else:
model = model.RNNModel(args.model, ntokens, args.emsize, args.nhid, args.nlayers, args.dropout, args.tied).to(device)

criterion = nn.CrossEntropyLoss()
criterion = nn.NLLLoss()

###############################################################################
# Training code
Expand Down

0 comments on commit 1800513

Please sign in to comment.