pytorch-nlp-tutorial-ny2018
pytorch-nlp-tutorial-ny2018 copied to clipboard
Day 1: Issues in notebook 3_classify_names_with_MLP.ipynb
1. About the third cell from the bottom, you have "labels" in there - to show the list of nationalities.
However, labels variable is only defined in the cell below it. Running code in order of cells will cause exception. You could remove it or move it below the confusion matrix.
2. Exersize -> Exercise spelling issue above the last cell.
3. Running the Exercise defaults to a deprecation warning "Calling softmax with implicit dimension is deprecated..."
You can fix this by editing the definition for forward function in your MLP() class to have the following lines when applying softmax:
if apply_softmax:
x = F.softmax(x, dim=1)