Intel® Distribution of OpenVINO™ Toolkit
Community support and discussions about the Intel® Distribution of OpenVINO™ toolkit, OpenCV, and all things computer vision-related on Intel® platforms.
5962 Discussions

Using Yolo Tensorflow for inteference openvino r2

abhi1
Beginner
813 Views

I converted my darknet yolo to tensorflow & then xml openvino .....tiny model following this guide: https://github.com/PINTO0309/OpenVINO-YoloV3

 

for creation of .xml I have used open r2. Now I want to do inference with TensorFlow YOLO...xml file

 

to do detection on Raspberry PI using webcam. Any instructions?

0 Kudos
1 Solution
JesusE_Intel
Moderator
399 Views

Hi abhi,

 

The OpenVINO toolkit for Raspberry Pi does not include the Object Detection Sample for YOLO. However, you should be able to copy the python sample from the OpenVINO toolkit for Linux and run it on your Raspberry Pi.

 

I am attaching the sample code included in the OpenVINO toolkit for Linux R2 2019. You can run the sample code on the Raspberry Pi with a camera with the following command.

python3 object_detection_demo_yolov3_async.py -m <your model.xml> -i cam -d MYRIAD

Hope this helps!

 

Regards,

Jesus

View solution in original post

7 Replies
JesusE_Intel
Moderator
400 Views

Hi abhi,

 

The OpenVINO toolkit for Raspberry Pi does not include the Object Detection Sample for YOLO. However, you should be able to copy the python sample from the OpenVINO toolkit for Linux and run it on your Raspberry Pi.

 

I am attaching the sample code included in the OpenVINO toolkit for Linux R2 2019. You can run the sample code on the Raspberry Pi with a camera with the following command.

python3 object_detection_demo_yolov3_async.py -m <your model.xml> -i cam -d MYRIAD

Hope this helps!

 

Regards,

Jesus

JesusE_Intel
Moderator
399 Views

Attaching the sample code from the OpenVINO toolkit for Linux R2 2019.

abhi1
Beginner
399 Views

Can you also provide me object_detection_demo_yolov3 tiny .........tiny ?

JesusE_Intel
Moderator
399 Views

The sample demo I provided should be able to run both YOLOv3 and tiny YOLOv3. Give it a try and let me know the outcome.

 

Regards,

Jesus

abhi1
Beginner
399 Views
abhi1
Beginner
399 Views

20190819_184530.jpgsomething wrong with predictions. Do you want me to share you the model & required stuff?

 

JesusE_Intel
Moderator
399 Views

Hi abhi,

 

What commands did you use to convert your model to IR format? Did you follow the Steps listed on the OpenVINO documentation for converting the weights to Tensorflow?

 

You command should look similar to this:

python3 convert_weights_pb.py --class_names <labes/names file> --data_format NHWC --weights_file <weight file> --tiny

 

To convert the TensorFlow model (pb) to IR, use the following command:

python3 <OpenVINO>/deployment_tools/model_optimizer/mo_tf.py --input_model <tensorflow model> --tensorflow_use_custom_operations_config <json file> --batch 1 --data_type FP16 --reverse_input_channels

 

If you converted the model differently, try to convert it again with the commands suggested above. Please send me your .pb file and .json file if you continue to have issues.

 

Regards,

Jesus

 

Reply