Skip to content

EvelinaAleksiutenko/Fruit-and-vegetables-classification

Repository files navigation

Fruit-and-vegetables-classification

Image classification using ResNet50 model and Flask web application. 2D TSNE visualization.


To see the video about testing web-app click here: ResNet-50 web-app for image classification
The dataset you can find here.

Requirements:

cuda_11.2
python version- 3.6.2

Algorithm:

Data augmentation I'm using tf.keras.preprocessing.image.ImageDataGenerator to make augmentation of images(spect ratio resizing, shifting, blurring, flipping)
Training a model I'm using tf.keras.applications.resnet50.ResNet50 with input shape of the image (224, 224, 3). Weights from imagenet dataset and max pooling in layers. Before fine-tuning accuracy was 0.90023.
Fine-tuning model As a fine-tuning I add this layers:

And the last five layers of the base model were also unfrozen and trained. After fine-tuning accuracy increased to: 0.92514.
2D visualization using TSNE I use TSNE to depict the distribution of classes.
Result:

Web application using Flask You can find video of testing my web application here. You can use my weights, which you can find in directory saved_model or you can train your model and save weights by running file Fruit-and-vegetables-classification

About

Image classification using ResNet50 model and Flask web application.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published