December 2018
Beginner to intermediate
684 pages
21h 9m
English
To obtain predictions from our trained model, we pass it feature data and convert the prediction to a NumPy array. We get softmax probabilities for each of the two classes, as follows:
test_value = Variable(torch.from_numpy(X)).float()prediction = net(test_value).data.numpy()prediction.shape(50000, 2)
From here on, we can proceed as before to compute loss metrics or visualize the result that again reproduces a version of the decision boundary we found.