Hi, I just downloaded the openmv IDE v. 4.7.0 and tried editing the romfs of my rt1062. I saw that there only a few models available inside the model zoo for my board. When disabling filtering by board , i could see tghe complete list of models including many variants for yolo inside the stm folder. My question is now, if its possible to run a simple yolo for the rt1062, and if so could you provide the files? Additionally do you have the .py file for the corresponding models inside the model zoo? Lastly it would be superful if you could provide a jupyter notebook showing how to train a yolo model with an additional category say number plate, and how to create the .tflite file.
Thanks a lot
Hi, all the YOLO models will run at like 0.06 fps on the H7 Plus and RT1062. They just can’t do it. However, the YOLO LC models will work. Use this script with any of the YOLO LC models in the ST folder.
I’ll be enabling these on the next release in examples:
# This work is licensed under the MIT license.
# Copyright (c) 2013-2025 OpenMV LLC. All rights reserved.
# https://github.com/openmv/openmv/blob/master/LICENSE
#
# TensorFlow Lite YoloLC Object Detection Example
import time
import sensor
import ml
from ml.postprocessing import yolo_lc_postprocess
import gc
sensor.reset()
sensor.set_pixformat(sensor.RGB565)
sensor.set_framesize(sensor.VGA)
sensor.set_windowing((400, 400))
import os
print(os.listdir("/rom"))
model = ml.Model("/rom/<model_name>")
model_class_labels = ["person"]
model_class_colors = [(0, 0, 255)]
print(model)
clock = time.clock()
while True:
clock.tick()
img = sensor.snapshot()
# boxes is a list of list per class of ((x, y, w, h), score) tuples
boxes = model.predict([img], callback=yolo_lc_postprocess(threshold=0.4))
# Draw bounding boxes around the detected objects
for i, class_detections in enumerate(boxes):
rects = [r for r, score in class_detections]
labels = [model_class_labels[i] for j in range(len(rects))]
colors = [model_class_colors[i] for j in range(len(rects))]
ml.utils.draw_predictions(img, rects, labels, colors, format=None)
print(clock.fps(), "fps")
You should get like 2 FPS.