I have developed a cluster of object detectors and now I want to use RabbitMQ to exchange messages between this cluster and the cameras themselves.
What I am trying to do is send the camera frames to the detector and the detector will reply to the cameras the content of the image.
As the content of what RabbitMQ sends has to be text only, I couldn't find a clear/good way to send the OpenCV images (I am using Python for that, so it's a np.ndarray) from the camera up to the cluster.
There were a couple of approaches that I found, but it usually transforms the image into a base64 string. The problem with that is that the images are usually really high resolution and take more time to convert the image to base64 back and forth than actually applying the objector itself. I am trying to make the process as efficient as possible on the message exchange/conversion.
The other approach I have seen was saving the image locally and only sending the image path, but what I am trying to do is consolidate every communication using RabbitMQ only.