abdullahselek / plant-disease-classification-tf

Disease classification on different plants with using Machine Learning and Convolutional Neural Networks.
MIT License
59 stars 20 forks source link
convolutional-neural-networks disease-classification opencv opencv-python plant-disease tensorflow

plant-disease-classification

A Convolutional Neural Network with TensorFlow and OpenCV using a dataset that contains different leafs of different plants. Repository has the dataset under plant_disease_classification/datasets folder.

Requirements

Training

Call trainer.py with train method with training and tests datasets.

python plant_disease_classification/trainer.py --train plant_disease_classification/datasets/train --val plant_disease_classification/datasets/test --num_classes 38

Model

After successfull training, model is created under plant_disease_classification/ckpts/ folder.

Classification

Call classify function of classifier.py with selected image file path. Below there is sample command for CLI for default image path.

python plant_disease_classification/classifier.py --classify

PyTorch Version

Another version of this project which is implemented using PyTorch and same datasets is available https://github.com/abdullahselek/plant-disease-classification-pytorch.

License

MIT License