CS194-26 Project 4: Classification and Segmentation

Vincent Zhu

The best results were achieved with a batch size of 64, with 32 channels for both convulational layers and 1568->68->10 features for the fully connected layers. I used Cross entropy loss and Adam with a learning rate of 0.005.

Training Accuracy Over 100 Epochs:

In [23]:
 
Out[23]:
[<matplotlib.lines.Line2D at 0x7f0dfc2265c0>]

Test Set Accuracy: 89.69%

Per Class Accuracy:

'T-shirt/top': 83.6%

'Trouser': 98.7%

'Pullover': 81.2%

'Dress': 88.3%

'Coat': 89.9%

'Sandal': 98.7%

'Shirt': 67.5%

'Sneaker': 94.6%

'Bag': 98.2%

'Ankle Boot: 96.2%

Hardest classes to identify: "Shirt" and "Pullover"

Correctly identified images: (two of each class, in the order listed above)

In [118]:
 
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)

Misclassified images: (two of each class, same order)

In [123]:
 
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)
(3, 28, 28)

Visualized filter from first layer:

In [133]:
 
First convolutional layer