element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • About Us
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Personal Blogs
  • Community Hub
  • More
Personal Blogs
Ralph Yamamoto's Blog Install OpenVINO on RPi4
  • Blog
  • Documents
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: ralphjy
  • Date Created: 30 May 2020 10:44 PM Date Created
  • Views 1443 views
  • Likes 2 likes
  • Comments 0 comments
  • rpi4
  • openvino
  • intel movidius ncs 2
Related
Recommended

Install OpenVINO on RPi4

ralphjy
ralphjy
30 May 2020

I'm getting an Intel Movidius NCS 2 Neural Compute Stick next week and I want to try using it with my RPi4 2GB, so I'm going to need to install the OpenVINO toolkit, the Model Optimizer and the Open Models Zoo repository.  I'm anticipating an arduous process.  I've used the first version of the NCS with a PYNQ-Z2 and an Ultra96 but haven't tried it with an RPi yet.  The installation of the NCSDK is pretty painless but the NCS 2 requires OpenVINO which appears to have a more complex installation.  The good news is that I should be able to use OpenVINO with both NCS and NCS 2 sticks so I should be able to try this out before I get the NCS 2.

 

First you need to download the latest version of the OpenVINO toolkit package for Raspbian OS from the IntelRegistered Open Source Technology Center.  Currently this is l_openvino_toolkit_runtime_raspbian_p_2020.2.120.tgz.

 

The package includes:

COMPONENTDESCRIPTION
Inference EngineThis is the engine that runs the deep learning model. It includes a set of libraries for an easy inference integration into your applications.
OpenCVOpenCV community version compiled for IntelRegistered hardware.
Sample ApplicationsA set of simple console applications demonstrating how to use Intel's Deep Learning Inference Engine in your applications.

 

 

Installation procedure:

  • Create an installation folder: sudo mkdir -p /opt/intel/openvino
  • Unpack the archive: sudo tar -xf  l_openvino_toolkit_runtime_raspbian_p_<version>.tgz --strip 1 -C /opt/intel/openvino
  • Install External Software Dependencies: sudo apt install cmake
  • Set the Environment Variables: echo "source /opt/intel/openvino/bin/setupvars.sh" >> ~/.bashrc
  • Add the current Linux user to the users group: sudo usermod -a -G users "$(whoami)"
  • Logout and login for command to take effect
  • Add USB Rules: sh /opt/intel/openvino/install_dependencies/install_NCS_udev_rules.sh

 

Test the installation:

  • Plug in Neural Compute Stick
  • Build and Run Object Detection Sample
    • Create a samples build directory: mkdir build && cd build
    • Build the Object Detection Sample:
      • cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_FLAGS="-march=armv7-a" /opt/intel/openvino/deployment_tools/inference_engine/samples/c
      • make -j2 object_detection_sample_ssd
    • Download the pre-trained Face Detection model:
      • Download the .bin file with weights: wget --no-check-certificate https://download.01.org/opencv/2020/openvinotoolkit/2020.2/open_model_zoo/models_bin/1/face-detection-adas-0001/FP16/face-detection-adas-0001.bin
      • Download the .xml file with the network topology: wget --no-check-certificate https://download.01.org/opencv/2020/openvinotoolkit/2020.2/open_model_zoo/models_bin/1/face-detection-adas-0001/FP16/face-detection-adas-0001.xml
      • Run the sample with specifying the model and a path to the input image: ./armv7l/Release/object_detection_sample_ssd_c -m face-detection-adas-0001.xml -d MYRIAD -i ~/Downloads/test.bmp

 

Installation failed!

     Or at least I think it did.  What is supposed to happen is that "The application outputs an image (out_0.bmp) with detected faced enclosed in rectangles".  Well, I don't see an image file created and I don't get any error messages.  The documentation isn't very helpful in that there is no sample image provided or an indication of where the expected output would go (I presume the directory you execute from but I can't find it there or anywhere else) and no indication of what the expected messaging is for a successful execution.  Here's what I see:

image

At least it appears to be at least running something.

 

I did determine that it seems to want a BMP image.  I gleaned that from running the command with the -h option:

image

 

I also tried running the OpenCV API Python example but unfortunately the error was not something that I can make sense of:

image

I sure wish Intel would provide test images and the expected outputs.

 

At this point I'm going to take a quick look at the source code for the C Object Detection Sample to see if I can get a clue as to what's failing.  The documentation did indicate that this has been validated with the RPi3 with both Stretch and Buster.  I'm running Buster on my RPi4.  Since I've never tried this on an RPi before and I've never used OpenVINO, I may have to drop back to trying the NCSDK on the RPi4.  If that doesn't work I may need to try both the NCSDK and OpenVINO on an RPi3.  I somehow suspected that this was going to be hard, but one should always have hope image.  Maybe somebody out there has got this particular configuration working and can tell me what I'm doing wrong.

  • Sign in to reply
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube