The goal of this project is to build and train a custom ResNet model with 50 layers which is able to classify different fruits and vegetables.
- TensorFlow 2.0.0
- Python 3.5.6
- Fruits-360 Dataset used for training and testing
- 82213 images of fruits and vegetables
- All images are RGB with dimensions 100 x 100 pixels
- Training set: 61488 images
- Test set: 20622 images
- Number of classes: 120
Images of each class are taken from all sides (360 degrees) of the fruit or vegetable.
model1.h5
has the following accuracy metrics:
- Training accuracy = 99.21%
- Validation accuracy = 92.50%
model1.h5
was trained for 20 epochs with a batch size of 32
- Using
anaconda
:- Run
conda create --name <env_name> --file tf2.yml
- Run
conda activate <env_name>
- Run
- Using
pip
:- Run
pip install -r requirements.txt
- Run
mkdir datasets
in the same directory assrc
- Download the Fruits-360 Dataset into
datasets
cd
tosrc
- Run
python main.py