Problem
A small startup builds devices that measure granule size above a conveyor in a mineral fertilizer plant. The plant checks granulation in a laboratory once every 4 hours, so tuning the process takes 1-2 days. Granules that stick into lumps (caking) waste raw materials, stop workshops and raise returned product. The devices must run 24/7 in dust, heat up to 100 C and bad network, and the team must develop models fast and ship them to many devices.
Example from the article: a conveyor at 1-2 m/s carrying 50 t/h must be measured about once a minute without a GPU.
Solution in brief
Split the work into science and industry. Prototype models in Jupyter, train with tracked experiments, export to ONNX and test on CPU in CI. Labelling, training and CI run on one GPU server, and Ansible ships models to edge devices. A small segmentation model plus classical OpenCV separates granules one by one.
Questions this case answers
- How to run a computer vision model on CPU-only edge devices and ship new models to many devices while keeping every experiment reproducible
- How to replace rare manual sampling with continuous quality measurement from images of a moving process
- How to build an MLOps pipeline for developing and deploying computer vision models for quality control in industrial environments
- How to run a computer vision model on CPU-only edge devices in a workshop
Tools and methods
- CVAT with Nuclio — labelling with SAM, later with own model pre-labelling
- PyTorch Lightning with ClearML — training and experiment log
- U-Net with MobileNet backbone, OpenCV — semantic mask, then classical splitting into granules
- ONNX, OpenVINO — CPU inference formats
- GitLab CI/CD, DVC, Ansible — tests, model storage and delivery to devices
- FastAPI, SQLite — data API and storage on the device
Google or a one-time email code. No password.
