I'm working on a combination of NCS2 and Raspberry Pi.
The main code at present is as follows.
I think it's probably asynchronous.
【 My Code 】
frame = PiAvLib.PiCamCapture(vs) #Get image data
blob = cv2.dnn.blobFromImage(frame, size=(640,480),ddepth=cv2.CV_8U)
out = net.forward()
out = np.squeeze(out)
Tagget_Chk(out, frame) #Add a box to a recognized object in the image
【 Question 】
Q1.Please tell me ,how to switch between synchronous and asynchronous processing of NCS2?
Q2.Please tell me ,the function to switch between synchronous and asynchronous.
Q3.Please tell me ,Where can I find a manual for switching between synchronous and asynchronous?
Thanks for reaching out.
For running synchronous or asynchronous inference, you can use the infer() or start_async() functions respectively. You can check these functions here.
Additionally, some demos such as the Object Detection YOLO* V3 Python* Demo feature the "Sync" and the "Async" ways toggled by the Tab key.