# Open Agri - Plant Disease Detection AI
This project focuses on identifying plant diseases using advanced Deep Learning models. It includes a user-friendly web interface powered by a multimodal Large Language Model (LLM) and specialized pipelines for Tomato Disease detection.
new/: Contains the interactive web application.main.py: A Gradio-based interface utilizing theYuchengShi/LLaVA-v1.5-7B-Plant-Leaf-Diseases-Detectionmodel for analyzing leaf images, describing symptoms, and suggesting treatments.
tomato-disease-ai/: A comprehensive pipeline for tomato disease classification and segmentation.dataset/&segmented_dataset/: Training and validation data directories.models/: Storage for trained Keras/H5 models.src/: Training scripts (train.py), utilities (utils.py), and evaluation scripts.segmentation/&patch_classifier/: Specialized scripts for image segmentation and patch-based classification.
Ensure you have Python installed. It is recommended to use a virtual environment or Conda environment to manage dependencies.
-
Clone the repository:
git clone https://github.com/Prathu241/open_agri.git cd open_agri -
Install General Dependencies (for
tomato-disease-ai):cd tomato-disease-ai pip install -r requirements.txt -
Install Dependencies for the Web App (
new/): The web app requires additional libraries likegradio,torch, andtransformers.pip install gradio torch transformers opencv-python pillow accelerator
This provides a polished, interactive web UI.
cd new
streamlit run streamlit_app.pycd new
python main.pyThis will launch a local Gradio server (usually at http://127.0.0.1:7860). Upload an image to get a detailed disease analysis.
To train the custom classifiers or segmentation models:
cd tomato-disease-ai/src
python train.py(Refer to individual scripts in tomato-disease-ai for specific segmentation or patch-based training tasks.)
- LLaVA-v1.5-7B-Plant-Leaf-Diseases-Detection: A fine-tuned multimodal model for comprehensive plant disease diagnosis.
- Custom CNNs/SegFormer: Tailored models for high-accuracy tomato leaf disease segmentation and classification.