Skip to main content

A library for plant disease detection using deep learning

Project description

plant_disease_lib

A Python library for plant disease detection using deep learning (CNN) and supplementary treatment information.

Features

  • Predict plant disease from leaf images using deep learning models
  • Return disease name, description, treatment/prevention steps, and recommended supplements
  • CSV-based metadata lookup for diseases and supplements
  • Torch-based model loading and inference
  • Easily extensible for new disease classes and models

Installation

Install via pip once released on PyPI:

pip install plant_disease_lib

Or clone the repository:

git clone https://github.com/P-r-a-n-a-v-N-a-i-r/plant-disease-lib.git cd plant-disease-lib pip install -e .

Usage

from plant_disease_lib import PlantDiseasePredictor

predictor = PlantDiseasePredictor( model_path='models/cnn_model.pth', disease_csv_path='data/disease_info.csv', supplement_csv_path='data/supplement_info.csv', num_classes=39 )

result = predictor.predict_with_metadata('test_image.jpg') print(result)

Example result output: { "index": 12, "disease_title": "Tomato Early Blight", "description": "...", "prevent": "...", "image_url": "...", "supplement_name": "...", "supplement_image_url": "...", "supplement_buy_link": "https://example.com" }

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

plant_disease_lib-0.1.4.tar.gz (4.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

plant_disease_lib-0.1.4-py3-none-any.whl (5.1 kB view details)

Uploaded Python 3

File details

Details for the file plant_disease_lib-0.1.4.tar.gz.

File metadata

  • Download URL: plant_disease_lib-0.1.4.tar.gz
  • Upload date:
  • Size: 4.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.0

File hashes

Hashes for plant_disease_lib-0.1.4.tar.gz
Algorithm Hash digest
SHA256 c78cc335db207a73f953d8b05967e055b72cb736a4714579b29d4308dd978a0c
MD5 08bc6cb692e6ce9ad54336c01ff1503d
BLAKE2b-256 55f2aba4fff0e610175c2f838b9433aa06d66965deaa04b92aeeb012faaaf060

See more details on using hashes here.

File details

Details for the file plant_disease_lib-0.1.4-py3-none-any.whl.

File metadata

File hashes

Hashes for plant_disease_lib-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 f92395ffbe940f9244cce65771d8e9a503163cc39a9f236aa4b8b4cc12541b0d
MD5 4a9db522b57b6c2da05ba357b82b9ff0
BLAKE2b-256 fea8486140b4390c53ee112b8f0fe464fc15b4926c0f256dd39e3e2732d7bd32

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page