Finding microplastics with computer vision
Can a cheap USB microscope and the right AI model let any school lab detect microplastics? A four-phase pipeline, four models, one fair comparison.
- My role
- First author, researcher & presenter
- Team
- 3 student researchers · advisor Dr. Dobri Atanassov Batovski
- Venue
- 11th International STEM Education Conference (iSTEM-Ed 2026)
- Tools
- Python, Google Colab, Roboflow, USB microscope
The problem
Microplastics, plastic particles smaller than 5 mm, are now found in oceans, rivers, soil and human tissue. Recent studies link them to cardiovascular risk and immune responses.
The accurate way to identify them, FTIR or Raman spectroscopy, is too expensive for most undergraduate labs. Counting particles by eye under a microscope is cheap, but slow, subjective and error-prone.
The gap we found
- No low-cost pipeline: existing AI tools assume expensive equipment or clean, lab-quality images.
- No fair comparison: segmentation and detection models report incompatible metrics (mIoU versus mAP), so they can't be ranked directly.
- No integrated STEM framework combining wet-lab chemistry, hardware and AI for undergraduates.
My role
I'm the first author of the paper. I worked through the full research cycle with two fellow students under our advisor: sample preparation, microscopy imaging, annotation in Roboflow, model training in Python on Google Colab, statistical analysis and writing.
I also built the conference slides and gave the oral presentation at the 11th International STEM Education Conference.
The process
- Wet lab: extract the particles
Sand from Bang Saen Beach, Chonburi, separated with saturated salt water. Plastics float and sediment sinks. Then fine-mesh filtration, air drying and optical confirmation.
- Hardware: low-cost imaging
A consumer 40× USB microscope with dual LED lighting. 4032×3024 images, resized to 1920×1080 and annotated by hand in Roboflow with bounding boxes and masks.
- AI: four models, three training stages
Two detectors (Faster R-CNN, YOLOv5) and two segmenters (U-Net, Mask R-CNN). Each learned basic shapes from a public dataset, was fine-tuned on 50 local beach images, then adapted with 30 curated images to cope with USB-microscope glare.
- Evaluation: one fair yardstick
We converted every model's output into bounding boxes using morphological opening, closing and contour detection, then scored all four on precision, recall and F1 at IoU ≥ 0.5. A Contamination Percentage (Cp) turns detections into an environmental severity measure.
The results
| Model | Precision | Recall | F1-score |
|---|---|---|---|
| Mask R-CNN | 0.7725 | 0.8249 | 0.7978 |
| Faster R-CNN | 0.7135 | 0.7740 | 0.7425 |
| U-Net | 0.7546 | 0.6949 | 0.7235 |
| YOLOv5 | 0.6215 | 0.8619 | 0.7222 |
Each model taught a different trade-off. YOLOv5 catches almost everything but with more false alarms, making it a screening tool. U-Net is the most precise but misses smaller particles, so it works best as a filter. Mask R-CNN is the best all-rounder.
Deep learning is viable for microplastics detection even on a student budget.
Limitations: optical identification only (no FTIR/Raman confirmation), particles must be larger than about 8 µm for the USB microscope, and the educational reflection comes from three student co-authors.