CIFAR-10, CIFAR-100 inference code

cifar10_predict

 

The code structure of inference/predict stage is quite similar to MNIST inference code, please read this for precise explanation.

Here, I will simply put the code and its results.

CIFAR-10 inference code

Code is uploaded on github as predict_cifar10.py.

This outputs the result as,

cifar10_predict

You can see that even small CNN, it successfully classifies most of the images. Of course this is just a simple example and you can improve the model accuracy by tuning the deep neural network!

 

CIFAR-100 inference code

In the same way, code is uploaded on github as predict_cifar100.py.

cifar100_predict

CIFAR-100 is more difficult than CIFAR-10 in general because there are more class to classify but exists fewer number of training image data.

Again, the accuracy can be improved by tuning the deep neural network model, try it!

 

That’s all for understanding CNN, next is to understand RNN, LSTM used in Natual Language Processing.

Next: Recurrent Neural Network (RNN) introduction

Sponsored Links

Leave a Reply

Your email address will not be published.