Created
August 19, 2018 03:15
-
-
Save omarsar/4605530586c794660f86f545ae009da3 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
test_acc = 0.0 | |
for i, data in enumerate(testloader, 0): | |
inputs, labels = data | |
inputs = inputs.view(-1, 28, 28) | |
outputs = model(inputs) | |
test_acc += get_accuracy(outputs, labels, BATCH_SIZE) | |
print('Test Accuracy: %.2f'%( test_acc/i)) | |
### output | |
''' | |
Test Accuracy: 96.97 | |
''' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment