We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f65e27f commit ebf9bfdCopy full SHA for ebf9bfd
tutorial-contents/302_classification.py
@@ -59,7 +59,7 @@ def forward(self, x):
59
if t % 2 == 0:
60
# plot and show learning process
61
plt.cla()
62
- prediction = torch.max(F.softmax(out), 1)[1]
+ prediction = torch.max(out, 1)[1]
63
pred_y = prediction.data.numpy().squeeze()
64
target_y = y.data.numpy()
65
plt.scatter(x.data.numpy()[:, 0], x.data.numpy()[:, 1], c=pred_y, s=100, lw=0, cmap='RdYlGn')
0 commit comments