PET Perplexity is an intelligent, automated polymer segregation system designed to revolutionize plastic waste management. It uses a cross-platform mobile application powered by advanced Computer Vision and Machine Learning to detect, classify, and analyze PET bottles in real-time.
The system addresses the challenge of segregating plastic waste by identifying key attributes such as bottle presence, size, brand, and material properties.
- Real-time Object Detection β Instantly detects PET bottles within a video feed or captured image.
- Bottle Size Classification β Automatically categorizes bottles into standard sizes (small, medium, large) to aid sorting logistics.
- Brand Recognition β Identifies the brand of a bottle using custom-trained deep learning models.
- Material Analysis β Uses XGBoost to analyze polymer characteristics for precise segregation.
- Batch Scanning β Processes multiple items at once for high-throughput environments.
- User Dashboard β A comprehensive mobile interface for tracking scan history and segregation statistics.
- Framework: Flutter (Dart)
- Platforms: Android, iOS, Web
- State Management: Provider / Riverpod (inferred)
- Architecture: Feature-first architecture (
lib/features/)
- Languages: Python, Node.js
- Frameworks: Flask, FastAPI / Uvicorn, Gradio
- Computer Vision:
- YOLOv5 / YOLOv8 β robust object detection and bounding box regression.
- OpenCV (
cv2) β image preprocessing and frame manipulation.
- Deep Learning Models:
- EfficientNet-B2 β fine-tuned for high-accuracy bottle size classification.
- Custom CNNs (PyTorch) β brand logo detection and classification.
- Machine Learning:
- XGBoost β tabular data analysis and material property prediction.
This repo is split across branches by service. main holds the mobile
app and two lightweight predictor services; the rest of the pipeline and
model training code live in separate branches.
| Branch | Contents | Live deployment |
|---|---|---|
main |
Flutter app (Android/iOS) + brand_predictor + dim_predictor |
NOT CURRENTLY DEPLOYED |
ML |
Integrated YOLOv5 + CNN + XGBoost pipeline | https://huggingface.co/spaces/SudoKuder/agglo |
bottlesize |
EfficientNet-B2 bottle-size classifier training + Flask API | NOT CURRENTLY DEPLOYED |
backend |
Node/Express REST API (auth, scans, MongoDB, Cloudinary) | https://pet-perplexity.onrender.com |
To run any service locally: git checkout <branch>, then follow that
branch's own README/requirements.txt.
Agglomeration-2.0/ (main branch)
βββ lib/ # Flutter app source
βββ android/ ios/ web/ # Platform targets
βββ brand_predictor/ # Logo detection + brand classification (Gradio, HF Space)
β βββ app.py
β βββ pipeline.py # Saliency transformer + two-stream EfficientNet-B2
β βββ model_arch.py
β βββ utils.py
βββ dim_predictor/ # Dimension estimation (Gradio, HF Space)
β βββ app.py # YOLOv8-seg + ArUco/cap-reference/camera-geometry calibration
β βββ README.md
βββ Problem Statement.pdf
βββ pubspec.yaml
Other branches:
βββ ML/ # Integrated YOLOv5 + CNN + XGBoost inference pipeline
βββ bottlesize/ # EfficientNet-B2 training + standalone Flask API
βββ backend/ # Node/Express API + MongoDB + Cloudinary
Current text says the Dimension Layer uses EfficientNet-B2. What's
actually deployed in dim_predictor is:
Dimension Layer: YOLOv8 segmentation isolates the bottle from the
background, then physical height/diameter are computed from the mask
using a three-way scale-calibration fallback: an ArUco marker if one is
visible in frame, otherwise a known bottle-cap diameter as a size
reference, otherwise camera geometry/distance. (EfficientNet-B2 was an
earlier size-classification approach, now developed separately in the
bottlesize branch as discrete volume classes β 33cl/50cl/100cl/150cl/200cl
β rather than continuous measurements.)
Contributions are always welcome!
- Fork the repository.
- Create a feature branch (
git checkout -b feature/AmazingFeature). - Commit your changes.
- Open a Pull Request.
| Name | Role |
|---|---|
| Aditya | Mobile App & UI/UX Development |
| Samarth Agarwal | Backend Development |
| Apurva Arya | AI & ML/DL Model Development |
| Arnav Tripathi | AI & ML/DL Model Development |
| Suryansh Kulshreshtha | AI & ML/DL Model Development |




