I have a project developed with OpenCV C++ where I process images taken from the camera. Normally my project runs smoothly at 30fps. Now I am trying to add an object detection algorithm working with yolov5s lbtorch to develop the project. But the hardware I’m using can run the object detection model at around 10fps. But 1 fps is enough for my project.
My problem is when I add object detection model to my project it works as 8-9 fps. Can I run object detection in the background at 1fps and run normal operations at 30fps? I tried to briefly explain what I want to do in the picture below. How can I do that?