CMSC 478 Spring 2022 - Homework 5
Due at the start of class on Monday March 9th
Get the example PyTorch CNN code that learns to classify CIFAR 10
images from here:
https://pytorch.org/tutorials/beginner/blitz/cifar10_tutorial.html
There are links at the top of that page to download the notebook
directly and to see it on GitHub where you can download it as well.
Here are your tasks and what you'll need to turn in for each of them:
- Run the notebook once without any modifications up to, but
not including, the cell that explains how to run on a GPU.
Running on the CPU will be fine for this homework. The last cell
you'll run shows the accuracy of the CNN for each of the 10
classes on the test data. Submit those accuracies as the first
thing in your writeup.
- Experiment with several (at least 4) ways of improving the
accuracy of the CNN. Some things you can consider include:
- Running training longer
- Changing the learning rate and other hyperparameters
- Increase or decrease the number of convolutional filters
- Change the number or sizes of the fully connected layers
- Change the size/stride of the filters
- Add more convolutional layers
- Try a nonlinearity other than ReLIU
- Add dropout
Make at least 4 changes to the network one at a time. That is,
try one change, revert back to the original network, try another
change, and repeat. The goal is to see the impact of one thing
by itself. For each change, write up why you think it will help
or hurt, submit the test accuracy for all of the classes, and
explain what happened (did it help or hurt accuracy and why?).
Then, create a final network using as many modifications as you
like, say what they are, and submit the final test accuracy
over all of the classes.
At least one change must involve modifying the structure of
the network, i.e., the number of layers, the sizes of layers,
the numbers of filters, etc.