How pellururambabu/ai-crop-detection-system works
This is a Streamlit crop-disease diagnostic dashboard. Users provide a leaf image from an upload or camera source; the app loads the serialized MobileNetV2 model, produces a diagnosis, and presents severity and treatment guidance. It also exposes ESP32 sensor telemetry and keeps scan records in session state for CSV export. The README describes additional supported acquisition modes and diagnostic outputs; the sampled source is partial, so those implementation details are not independently verified here.
Main entry points: app.py Diagnosis Result · crop_disease_model.pkl Model Artifact
Components 17
Image Acquisition
- Image Upload
app.py - USB Camera
app.py - ESP32 Camera
app.py - Active Image
app.py
Diagnosis
- Image Preprocessing
app.py - Model Loader
app.py - Model Artifact
crop_disease_model.pkl - Disease Classifier
app.py - Diagnosis Result
app.py - Treatment Guidance
app.py
Field Monitoring
- Sensor Polling
app.py - Telemetry Display
app.py
Results and Records
- Diagnostic Dashboard
app.py - Session Scan Log
app.py - CSV Export
app.py
Other components
- Field User
- ESP32 Device
Connections 21
- Field User → Image Upload: uploads image
README.md - Field User → USB Camera: captures image
README.md - Field User → ESP32 Camera: requests capture
README.md - Image Upload → Active Image: sets image
README.md - USB Camera → Active Image: sets image
README.md - ESP32 Camera → Active Image: captures frame
app.py - Active Image → Image Preprocessing: normalizes image
README.md - Image Preprocessing → Disease Classifier: provides tensor
README.md - Model Loader → Model Artifact: loads weights
app.py - Model Loader → Disease Classifier: constructs model
app.py - Disease Classifier → Diagnosis Result: returns prediction
README.md - Diagnosis Result → Treatment Guidance: drives guidance
README.md - Diagnosis Result → Diagnostic Dashboard: renders diagnosis
app.py - Treatment Guidance → Diagnostic Dashboard: renders guidance
app.py - Field User → Sensor Polling: configures device
app.py - Sensor Polling → ESP32 Device: requests telemetry
app.py - Sensor Polling → Telemetry Display: provides readings
app.py - Telemetry Display → Diagnostic Dashboard: renders status
app.py - Diagnosis Result → Session Scan Log: appends scan
app.py - Session Scan Log → CSV Export: exports records
README.md - CSV Export → Field User: downloads CSV
README.md