I am using Movidius NCS on Raspberry pi 4 with USB-3 with the power supply and communication to and from the Raspberry Pi using Serial Pins, I am using Movidius to test a classification model which is giving me around 23 Frames Per Second.
Sometimes I am getting the FPS around 17 instead of 23, I am not sure what exactly is causing the problem, it's definitely not the temperature as it occurred when its cool and not used for a long time.
Is there any way that the voltage from the Serial Port to power the Raspberry Pi is affecting the Movidius or any other reason which is causing the Movidius to slow down the performance?
Thank you for reaching out.
Please provide us the following information:
1- Could you please clarify to us if you are using a powered USB hub? If you are not, please share the specifications of the Raspberry Pi power supply.
2- Are you using an OpenVINO pre-built package or are you using the DLDT? Can you share with us the model, so we can test it from our end?
3- Also, please provide us more details about the classification sample and model used. Are they customed or are you using the ones provided in the toolkit?
4- Additionally, let us know how long does it take when running the sample for the FPS to drop?
1) Not using powered USB hub, Raspberry pi 4 is connected to the firmware configured board using the Serial pins on the Raspberry Pi, the firmware configured board is powered with the 12V battery and the power is transmitted to the Raspberry Pi using the Serial pins. The voltage at the Raspberry pi is reduced to approximately 4.83 volts to power it on, Movidius NCS 2 is connected to the USB-3 port of the Pi.
2) I am using the OpenVINO toolkit version 2019_R3.1. I have attached the TensorFlow full model(not the TensorFlow lite) .pb file, the input size of the image for the model should be 224*224. I usually run the model using the OpenCV library soft link from the OpenVINO toolkit using the code in the program as cv2.dnn.blobFromImage(image.astype('float32'),1.0/255.0,(224,224),swapRB=True,crop = False,ddepth=cv2.CV_32F).
3) It is the custom made model that is used to classify if there is a weed in the given grass image. I usually get around 23 FPS when I run it from the Pi, but sometimes even without the frequent runs of the program, it drops to around 17 FPS when I run it the first in the morning after powering on the circuit even after the Pi is powered off for 12 hours.
4) There isn't any fixed pattern or time for the FPS to drop after starting the frames from PiCamera. It happens on an average of once a week after running the program on different days in the week. When the FPS drops I had to remove the entire circuit and use it to power the PI with the regular Type-C and use it to try and run the same program which never gives the output of the model as it reboots the PI when the program tries to use the Movidius. After many reboots trying to run the model using Movidius for half an hour, I connect back the PI to the firmware board to power it using the Serial Ports and run the Program with the model, which gets the FPS back to normal around 23. I couldn't find the cause of reboots while using the Movidius NCS, but temporarily brings back the FPS on the Circuit to around 23 FPS and I use to wait for the next drop in FPS to occur someday and had to do the above process again to fix it.
I need the permanent fixation so that the FPS won't drop, can't isolate the Raspberry Pi every time the issue occurs. Not sure why the reboots occur after isolating it and trying to run the model with Movidius.
A drop in frame rate especially at random times can usually be attributed to a power issue, but since you are not using a USB powered hub this could be something else.
I'd like to run this on my end to see if I experience the same drop in frame rate. You mentioned that you attached your model, but I don't see it. Can you please attach it again? If it is a custom model, I can PM you and you can send it there if you don't want to share it publicly.
I apologize for the delay in my response. I have tested the model on my Raspberry Pi but did not experience a major drop in framerate. I was using a standalone RPI. Since this is a random occurrence it might be difficult to reproduce the issue.
I think you may be right in thinking that there is not an adequate amount of power being transmitted from the serial port to the Raspberry Pi.
Have you tried running one of the OpenVINO object detection SSD samples to see if there is a drop in framerate?
Thank you, we have increased the power supply for raspberry pi a bit over 5V, seems to be working fine as far as now. I haven't tried any SSD samples yet, sure will check on that.