CV / YOLACT

YOLACT-RegNetX-1.6GF

reComputer R Series (CM5 + Hailo-10H)

Real-time instance segmentation (COCO 80 classes, masks + boxes) on reComputer R Series with Hailo-8 or Hailo-10H.

84 downloads
Size
36 MB
Memory
4GB+
Precision
Hailo HEF / HailoRT

Choose the device you're using, the set up guide and documentation will update accordingly.

Getting Started

Deploy
sudo docker run --rm \
  --name cm5-hailo10h-yolact-1-6gf \
  --privileged \
  --net=host \
  -e PYTHONUNBUFFERED=1 \
  --device /dev/hailo0:/dev/hailo0 \
  -v /usr/lib/libhailort.so.5.1.1:/usr/lib/libhailort.so.5.1.1:ro \
  -v /usr/lib/libhailort.so:/usr/lib/libhailort.so:ro \
  ghcr.io/seeed-projects/recomputer-hailo10h-cv/yolact_regnetx_1_6gf:latest \
  python web_detection.py --model_path model/yolact_regnetx_1_6gf.hef --video_path video/test.mp4

REST API

Use the REST API to run inference. Copy the commands below.

Curl
curl -X POST "http://<Board_IP>:8000/api/models/yolact_regnetx_1_6gf/predict" \
  -F "file=@test.jpg"
Python
import requests

response = requests.post(
    "http://<Board_IP>:8000/api/models/yolact_regnetx_1_6gf/predict",
    files={"file": open("test.jpg", "rb")},
    timeout=30,
)
print(response.json())

Model Details

reComputer R Series (CM5 + Hailo-10H)

YOLACT-RegNetX-1.6GF on reComputer R Series (CM5 + Hailo-10H)

YOLACT (UC Davis) performs real-time instance segmentation — per-object masks on top of COCO 80-class boxes — on Hailo-10H through HailoRT 5.1.1. The HEF exposes 16 raw heads and all decode runs on the host CPU.

Model Info

PropertyValue
ArchitectureYOLACT (You Only Look At CoefficienTs), RegNetX-1.6GF backbone
TaskInstance segmentation
Input512x512x3 RGB (normalize_in_net ImageNet RGB mean/std)
Output16 heads: proto (128x128x32) + 5 scales x {bbox, mask coeffs, conf}
Priors49,104 anchors (9/cell, feature maps 64/32/16/8/4)
Classes80 (COCO)
Parameters30.09M
Operations125.34G
HEFHailo Model Zoo v5.4.0, Hailo-10H (38.9 MB)

Hardware and Host Setup

ItemValue
BoardreComputer R Series with Raspberry Pi CM5
AcceleratorHailo-10H over PCIe, exposed as /dev/hailo0
Host driverhailo-h10-all apt package
RuntimeHailoRT 5.1.1
Python in container3.13, aarch64
bash
sudo apt update
sudo apt install hailo-h10-all -y
sudo reboot

# After reboot
hailortcli fw-control identify
ls /dev/hailo0

Run With Demo Video

bash
sudo docker run --rm \
  --name cm5-hailo10h-yolact-1-6gf \
  --privileged \
  --net=host \
  -e PYTHONUNBUFFERED=1 \
  --device /dev/hailo0:/dev/hailo0 \
  -v /usr/lib/libhailort.so.5.1.1:/usr/lib/libhailort.so.5.1.1:ro \
  -v /usr/lib/libhailort.so:/usr/lib/libhailort.so:ro \
  ghcr.io/seeed-projects/recomputer-hailo10h-cv/yolact_regnetx_1_6gf:latest \
  python web_detection.py --model_path model/yolact_regnetx_1_6gf.hef --video_path video/test.mp4

Open http://<Board_IP>:8000 to view the web preview (colored instance masks overlaid on the MJPEG stream).

REST API

bash
curl -X POST "http://<Board_IP>:8000/api/models/yolact_regnetx_1_6gf/predict"   -F "file=@test.jpg"
EndpointMethodPurpose
/api/models/yolact_regnetx_1_6gf/predictPOSTBoxes, confidences, mask areas (JSON)
/api/video_feedGETMJPEG preview stream with masks

Implementation Notes

  • CPU post-processing (meta_arch=yolact): 49,104 anchors → SSD decode → Fast NMS → sigmoid(proto @ coeffs^T) mask assembly — numpy port of the Model Zoo's instance_segmentation_postprocessing.py.
  • Executor is the HailoRT 5.1.1 multi-output FLOAT32 wrapper (16 heads); first inference prints each head's value range per the SOP acceptance checklist.
  • normalize_in_net ImageNet RGB; the app feeds raw uint8 RGB.
  • Preprocessing: plain bilinear resize to 512x512 (no letterbox, no pad).

Development Notes

  • Source module: src/hailo10h_yolact_regnetx_1_6gf/
  • Dockerfile: docker/hailo10h/yolact_regnetx_1_6gf.dockerfile
  • Container: ghcr.io/seeed-projects/recomputer-hailo10h-cv/yolact_regnetx_1_6gf:latest
  • Family: YOLACT (variants: regnetx_800mf / regnetx_1.6gf)

Inputs and Outputs

Input: image, video, or USB camera frame. Output: COCO 80-class boxes with confidences, per-object mask pixel areas, and an MJPEG preview with colored instance masks.