About the Disposify Project
Disposify is an AI-powered waste detection and alert system designed to nudge users towards proper waste disposal and provide organizations with insights into their waste management practices. We aim to minimize waste contamination and promote a more sustainable future.
Inspiration
In a world where 160 million tons of trash pour into our landfills annually, with over 50% being food waste, plastics, and paper/paperboard, the need for responsible waste management is critical. Inspired by this urgency, we developed Disposify to address the growing landfill problem and promote a healthier, more sustainable planet for future generations. We are also inspired by personal anecdotes on Amherst campus.
What it does
Disposify uses a locally hosted web app with YOLOv11 for real-time trash detection. Key features include:
- Real-time Detection: Employs a YOLOv11 model to identify waste items via laptop camera or cloud GPU (Google Colab).
- User-Defined Detection Zones: Allows users to define specific areas within the camera's view for detection.
- Audio Alarms: Provides immediate audio feedback for both correct and incorrect waste disposal.
- Inference Speed Benchmarking: Tracks and optimizes the model's processing speed.
- Real-time Analytics Dashboard: A dashboard that visualizes waste disposal data, offering insights into waste patterns. This is accomplished through utilization of Supabase Realtime, which dynamically updates graphs/alarm logs with Tremor components.
- Targets student/staff confusion about recycling Reduces contamination with alert notifications.
- Provides custodial teams contamination metrics Logs what and how often alerts occur.
- Supports sustainability office with live waste diversion data By tracking what exactly is being thrown in the trash, what exactly isn't, and graphing that information to allow for analysis.
How we built it
Disposify leverages a modern tech stack to achieve its functionality:
- Frontend:
- Next.js (App Router) with Shadcn UI for a responsive and customizable user interface.
-
react-webcamto capture the camera feed and allow for drag-and-draw zone selection. - Tremor for analytics visualization and Tailwind CSS for styling.
- Backend:
- FastAPI for creating the API endpoints (
POST /detect,GET /analytics). - Ultralytics YOLOv11 (Python/Conda) trained on a Roboflow dataset (https://universe.roboflow.com/proje-nkf76/atik-ayristirma) for object detection.
- FastAPI for creating the API endpoints (
- Database:
- Supabase (PostgreSQL) for storing logs and analytics, using Supabase Realtime for live dashboard updates.
- Data Flow
- User drags and draws opague boxes to define detection zones.
- Frontend Camera Feed captures the frames.
- The API request sends the frames to the YOLOv11 model on the backend, which then processes frames and returns waste class/coordinates and inference speed.
- If there are any errors, that also gets logged.
- The Waste type, timestamp, disposal correctness, and alarm events get sent to the database, where the dashboard pulls the DB data to update graphs/alarm logs. It updates these graphs with indicators that show what data is historical and what data is being updated live.
Challenges we ran into
We encountered several challenges during the development process:
- Data Training: Ensuring the YOLOv11 model was trained on a comprehensive and accurate dataset to achieve reliable object detection.
- Frontend-Backend Integration: Seamlessly linking the frontend and backend to handle camera input, API requests, and real-time data updates.
- Detection Zone Setup: Implementing an intuitive and accurate method for users to define detection zones within the camera's field of view.
- Balancing performance and accuracy. We experimented with different YOLOv11 settings and model sizes.
- Optimizing audio playback. Getting the correct audio cues and ensuring they don't block program execution.
Accomplishments that we're proud of
We are particularly proud of:
- Dashboard Analytics: Developing a user-friendly dashboard that provides valuable insights into waste disposal patterns.
- CNN Model Integration: Successfully connecting the YOLOv11 model to the user interface, creating a cohesive and functional system.
- Detection Zones: Implementing effective detection zones that accurately capture waste disposal events.
- UI Customizability: Offering a customizable user interface to tailor the system to specific needs.
- Customization to Amherst's Zero-Waste goal: This project is built specifically to help reduce the contamination and waste diversion issues present at Amherst College.
What we learned
Through this project, we gained invaluable knowledge and experience in:
- Full-Stack Development: Understanding the intricacies of building a complete web application using a modern tech stack.
- CNN Models & Object Detection: Deepening our understanding of Convolutional Neural Networks (CNNs) and their application in object detection.
- User Interface Design: Learning best practices for designing intuitive and user-friendly interfaces.
- Data visualization: Gained experience turning raw data into actionable insights via dashboards.
- Importance of Dataset. The dataset is integral to a good system.
- Team Collaboration How to work effectively in a team environment with diverse skill sets and backgrounds.
What's next for Waste Detection
Our next steps for Disposify include:
- Real-World Implementation: Deploying the system in real-world settings, such as Valentine Dining Hall and the Science Center at Amherst College, using iPads near waste disposal areas.
- Data Refinement: Gathering real-world data from student disposal habits to further train and improve the YOLOv11 model.
- UI/UX Improvement: Enhancing the integration of UI components with image detection for a more seamless user experience.
- Expanding object recognition To recognize all forms of trash to offer a wider ranger of accurate results.
- Multi-Bin Support: Implementing support for multiple waste bins with distinct audio cues for each.
- Dynamic Sound Assignment: Allowing administrators to customize the audio feedback based on disposal correctness.
- Edge Deployment: Running the object detection model on edge devices for faster processing and reduced latency.
- Improved object detection accuracy: By expanding the training data set and refining the algorithm.
Our ultimate goal is to create a scalable and impactful solution that promotes responsible waste management practices worldwide.
Built With
- fastapi
- next.js
- python
- supabase
- ultralytics
- yolo
Log in or sign up for Devpost to join the conversation.