Skip to content

This project utilizes deep learning for fruit image classification using the Fruits 360 dataset. A CNN model is trained to accurately recognize various types of fruits. This submission is made for the Belajar Fundamental Deep Learning course on Dicoding as part of learning and applying deep learning in image classification.

Notifications You must be signed in to change notification settings

atifa1110/Fruit-Classification

Repository files navigation

Fruits Image Classification

Fruits Image Classification

Background:

Image recognition is a major field within machine learning and computer vision. Thanks to technological advances, the image classification process has become easier and can be applied across various sectors, ranging from security systems to healthcare services. This project focuses on fruit image classification to understand the application of deep learning models in distinguishing different types of fruits.

Business Problem:

In the retail and food industries, the ability to automatically recognize fruits greatly helps optimize processes such as sorting, packing, and quality control of fruits. Automation reduces human errors, increases productivity, and lowers operational and labor costs for companies.

Project Objectives:

  1. Develop an image classification model capable of identifying various fruit types with high accuracy.
  2. Save the model in multiple formats compatible with different platforms and devices.
  3. Apply deep learning to improve image classification accuracy.

Project Scope:

  1. Search for a dataset
  2. Split the dataset into 80% training set and 20% test set
  3. Use a Sequential model with Conv2D and pooling layers
  4. Plot model accuracy and loss graphs
  5. Save the model in SavedModel, TF-Lite, and TFJS formats
  6. Implement callbacks
  7. Perform inference using one of the models (TF-Lite, TFJS, or SavedModel with TensorFlow Serving).

Dataset

Dataset is obtained from Kaggle’s Fruits Dataset, which contains 5 folders:

  1. fruits-360_100x100
  2. fruits-360_3-body-problem
  3. fruits-360_dataset_meta
  4. fruits-360_multi
  5. fruits-360_original-size

For this project, only the fruits-360_100x100 folder is used. This dataset contains 207 classes.

  1. Recommended to run on Google Colab

    • Upload the file [Deep Learning]_Submission_Klasifikasi_Gambar_Atifa_Fiorenza.ipynb to Google Colab
    • Adjust or customize the existing code as needed
    • Run run all on the project
  2. If running locally

    • Make sure you are connected to the internet to install required modules (libraries)
    • Open cmd or PowerShell as administrator
    pip install -r requirements.txt
    • Open File [Deep Learning]_Submission_Klasifikasi_Gambar_Atifa_Fiorenza.ipynb tp Google Colab
    • Adjust or customize the existing code as needed
    • Do run all in project

Conclusion

  • Based on experiments, the results are:
    • Model : Sequential
    • Train Accuracy : 96%
    • Test Accuracy : 98%
  • The model is able to predict fruit images inputted through inference.

Suggestions

  • Further experiments using other pretrained models in this project (e.g., VGG, ResNet, etc.)
  • Conduct additional experiments using the original and multi datasets

About

This project utilizes deep learning for fruit image classification using the Fruits 360 dataset. A CNN model is trained to accurately recognize various types of fruits. This submission is made for the Belajar Fundamental Deep Learning course on Dicoding as part of learning and applying deep learning in image classification.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published