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.3.tar.gz (3.9 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.3-py3-none-any.whl (5.0 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: plant_disease_lib-0.1.3.tar.gz
  • Upload date:
  • Size: 3.9 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.3.tar.gz
Algorithm Hash digest
SHA256 f5f7f07219e3dc126bfa71f39ba2f7d7994cfb0c8d34faba72024644a6bc1b42
MD5 19444a2704aee9237b7822102c8695d9
BLAKE2b-256 83ea902006510849242bf3f85b7506fc8d4061ca8350550ac5e010ee5b544c29

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for plant_disease_lib-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 b78306df5cc16fd26f353a9a3b9c992eacef64c0830227810618ed9ea433dad5
MD5 b2e76be77f832ac3c18204e8d759b72e
BLAKE2b-256 0cf819be1f25f6c7f29c40124ee54a980f786ee0a15d8ebda49fc174b39f5f29

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