Skip to content

krassiaa/CV

Repository files navigation

Image Classification: Fruits, Vegetables, and Flowers

This project aims to create models for binary and multi-class image classification using various deep learning architectures in TensorFlow/Keras.

Contents

Description

The project includes two classifications:

  1. Binary Image Classification: Distinguishes between fruits and vegetables.
  2. Multi-class Classification: Identifies different types of flowers.

Both tasks involve several deep learning models, including:

  • Custom model
  • VGG16 model
  • MobileNetV3Large model
  • EfficientNetB0 model
  • Xception model

Installation

  1. Clone the repository:

bash git clone https://your-repo-url.git cd your-repo-name

  1. Make sure the required libraries are installed: bash pip install tensorflow pandas matplotlib scikit-learn imbalanced-learn tqdm albumentations

  2. Download and prepare the necessary data: Place your images in the directories specified in the code (train_set, val_set, test_set).

Technologies Used

  • Python 3
  • TensorFlow
  • Keras
  • Pandas
  • Matplotlib
  • OpenCV (for augmentation)

Methods

Data Preparation: The data was split into training, validation, and test sets. Data Augmentation: Augmentation methods (flipping, resizing, contrast adjustment) were applied to improve model quality. Model Building: Each model was built and trained using the appropriate architectures. Model Evaluation: Models were evaluated on the test dataset, and results were collected.

Useful Links

Datasets

Binary Classification

Dataset Description

The dataset was collected independently and contains images of fruits and vegetables. Below are the sources from which the images were obtained:

Multi-Class Classification

For multi-class classification, I used the 102 Category Flower Dataset, created by Maria-Elena Nilsback and Andrew Zisserman. The dataset consists of 102 flower categories, each containing between 40 and 258 images of flowers commonly found in the United Kingdom.

Dataset Description

  • The dataset features a wide scale, pose, and lighting variations, making it suitable for robust image classification tasks.
  • Each class is stored in separate folders and includes a variety of images, providing diversity and complexity for the classification model

Citation

If you use this dataset in your research or projects, please cite the following publication:

Nilsback, M-E., & Zisserman, A. (2008). Automated flower classification over a large number of classes. In Proceedings of the Indian Conference on Computer Vision, Graphics and Image Processing.

License

The dataset is available for use under the terms outlined on the Oxford VGG website. Ensure to check the specific usage guidelines provided there.

Download Link

You can access the dataset through this link.

License

This project is licensed under the MIT License - see the LICENSE file for details.