Inspiration

Last year, one of our team members hit a deer while driving home, the car was damaged, and a chain-reaction collision nearly injured the driver behind. That moment sparked a question: why isn't there a smarter way to prevent this? We discovered that 1.9 million wildlife-vehicle collisions happen every year in the U.S., causing 200 deaths and $8 billion in damages. California recently spent $92 million on a single wildlife crossing - effective, but impossible to scale. We set out to build something affordable, deployable anywhere, and intelligent enough to protect both drivers and wildlife.

What it does

Our system uses a camera positioned near the road to continuously capture video of the surrounding area. The footage is processed using computer vision algorithms to detect and identify animals near the road, as well as suspicious individuals in the monitored area. When an animal is detected, the system generates a real-time alert through a mobile app and marks the animal's location on a map interface to warn nearby drivers. At the same time, the system activates a speaker that emits sounds at frequencies tailored to deter specific animals identified by the camera. If a suspicious individual is detected, an alert is sent to a monitoring dashboard by law enforcement to view.

How we built it

We built a three-tier architecture: a Raspberry Pi with a camera streams live video via WebRTC to a cloud-based ML service on Render, which sends alerts to a Flutter mobile app for drivers. For the ML pipeline, we experimented with YOLO-World (18% accuracy) and fine-tuned YOLOv8 (50% after fixing data leakage). The breakthrough came with OpenAI's CLIP model—achieving 100% accuracy across 12 wildlife species using zero-shot classification, no training data required. To fit Render's 512MB memory limit, we converted the model to ONNX Runtime, reducing memory from 1.5GB to 300MB. The backend runs on FastAPI with WebRTC for real-time streaming. The mobile app is built in Flutter, displaying animal alerts on an interactive map as drivers approach danger zones.

Problems we run into

  1. Data leakage: Our fine-tuned model showed 98.5% accuracy—until we realized frames from the same videos were in both training and test sets. True accuracy: 50%.
  2. Memory constraints: CLIP required 1.5GB RAM, but our cloud instance only had 512MB. We solved this by converting to ONNX Runtime.
  3. WebRTC reliability: Establishing stable peer-to-peer video connections between a Raspberry Pi and cloud server required extensive debugging of ICE candidates and TURN servers.
  4. Human detection tuning: Distinguishing between a person walking normally vs. someone collapsed required careful prompt engineering in CLIP.

Accomplishments that we're proud of

100% wildlife detection accuracy using zero-shot CLIP—no custom training data needed

  • Real-time alerts delivered to drivers in under 1 second
  • Species-specific deterrents: Different ultrasonic frequencies for different animals (20kHz for deer, 2kHz for bears)
  • Memory optimization: Reduced ML model footprint by 80% to run on low-cost infrastructure
  • Successfully integrated hardware (Raspberry Pi + speaker) → cloud ML → mobile app into one seamless system

What we learned

Pre-trained models beat fine-tuning when you have limited data—CLIP's 400M image training set outperformed our custom dataset

  • Data leakage is subtle and dangerous, always split by source, not by frame
  • WebRTC is powerful but complex, NAT traversal and TURN servers are essential for real-world deployments
  • Prompt engineering matters—the right text descriptions dramatically improve zero-shot classification accuracy

What's next for WildWatch: A Wildlife Detection System for Road Safety

Solar-powered units for remote highway deployment

  • Integration with vehicle infotainment systems (CarPlay, Android Auto)
  • Expand detection to include road hazards (debris, flooding, accidents)
  • Partner with DOTs to pilot on high-collision corridors
  • Edge inference on Raspberry Pi 5 to reduce cloud dependency

Built With

Share this project:

Updates