π± AgriVision AI β From Detection to Real-World Decisions
π Inspiration
This project started from a simple question:
Why do AI models perform well in metrics, but struggle in real-world agricultural environments?
While exploring weed detection in crop fields, I realized that many existing approaches focus heavily on model accuracy, but overlook how these models behave under real conditions β especially when decisions directly affect physical outcomes such as crop damage.
This curiosity led me to build a system that not only detects weeds, but also evaluates how usable those detections are in practice.
π§© Problem
During development, I discovered a key limitation:
The training dataset (from Kaggle) used large bounding boxes covering entire weed regions, rather than individual plants.
As a result, the model learned to detect aggregated weed areas instead of discrete plant instances.
This created several real-world issues:
- Over-detection in dense areas
- Large, imprecise bounding boxes
- Difficulty distinguishing crop vs weed
- Inflated weed counts
π οΈ Solution
Instead of treating this as a model-only problem, I approached it as a system-level challenge.
I introduced an OpenCV-based post-processing layer that:
- Filters unrealistic bounding boxes
- Applies Non-Max Suppression (NMS)
- Removes noise and extreme detections
- Refines detection outputs into more meaningful plant-level approximations
This significantly improved the practical usability of the model.
βοΈ How It Works
The system pipeline:
- Image input (field image or video frame)
- TFLite-based object detection model
- Output parsing and normalization
- Post-processing layer (filtering + NMS + heuristics)
- Visualization (bounding boxes, metrics, density)
- Decision support outputs (weed count, density, insights)
π Key Features
- πΏ Weed detection with real-time visualization
- π₯ Video frame analysis
- π Weed density estimation
- π§ Post-processing for real-world reliability
- π Insight layer for decision support
β‘ What Makes It Different
Most projects stop at βmodel predictionβ.
This project focuses on:
Bridging the gap between model output and real-world usability
Instead of optimizing only for accuracy, it addresses:
- dataset limitations
- model behavior in field conditions
- practical interpretation of predictions
π What I Learned
- Dataset quality directly shapes model behavior
- High mAP β usable system
- Post-processing is critical in real-world AI
- Understanding why a model behaves a certain way is more important than just improving metrics
π₯ Challenges
- Handling noisy detections and overlapping boxes
- Dealing with dataset-level limitations
- Preventing over-detection in dense scenes
- Balancing precision vs usability
π Future Work
- Retrain model using datasets with per-plant annotations (e.g., DeepWeeds, CottonWeed)
- Improve crop vs weed classification
- Add GPS-based field mapping
- Integrate decision-making systems for precision agriculture
- Extend to real-time deployment on edge devices
π‘ Final Thought
This project is not just about detecting weeds.
It is about designing AI systems that work reliably in the real world, where every prediction can lead to a physical action.
And thatβs where true impact happens.


Log in or sign up for Devpost to join the conversation.