openvinotoolkit / open_model_zoo

Pre-trained Deep Learning models and demos (high quality and extremely fast)
https://docs.openvino.ai/latest/model_zoo.html
Apache License 2.0
4.1k stars 1.37k forks source link

Cannot load library 'libopenvino_intel_myriad_plugin.so' #3703

Closed amphancm closed 1 year ago

amphancm commented 1 year ago

### I've use OpenVINO 2022.3 on Raspberry pi ( 64 bit ) + Intel NCS2

Show error pi@raspberrypi:~/omz_demos_build $ ./aarch64/Release/interactive_face_detection_demo -m ./models/face-detection-adas-0001.xml -d MYRIAD -i /home/pi/Videos/face-demographics-walking.mp4 [ INFO ] OpenVINO [ INFO ] version: 2022.3.0 [ INFO ] build: 2022.3.0-9052-9752fafe8eb-releases/2022/3 [ INFO ] Reading model: ./models/face-detection-adas-0001.xml [ INFO ] Model name: mobilenet_ssd_672x384 [ INFO ] Inputs: [ INFO ] data, f32, [1,3,384,672], [N,C,H,W] [ INFO ] Outputs: [ INFO ] detection_out, f32, [1,1,200,7], [...] [ ERROR ] Cannot load library 'libopenvino_intel_myriad_plugin.so: libopenvino_intel_myriad_plugin.so: cannot open shared object file: No such file or directory

### How to build 'libopenvino_intel_myriad_plugin.so' ?

But use -d CPU work fine.

DariaMityagina commented 1 year ago

@amphancm hello! Could you please share the steps you took and the commands you used (e.g. cmake) to build Openvino with the Myriad plugin?

amphancm commented 1 year ago

@DariaMityagina Hi! Thank you for reply.

For OpenVINO Toolkit Install OpenVINO™ Runtime for Raspbian OS ( 64 bit ) [https://docs.openvino.ai/latest/openvino_docs_install_guides_installing_openvino_raspbian.html]

For Open Model Zoo Demos Build the Demo Applications on Linux [https://docs.openvino.ai/latest/omz_demos.html]

build_demos.sh -DENABLE_PYTHON=y

so How to build Myraid plugin?

DariaMityagina commented 1 year ago

@amphancm hi!

Could you please try building Openvino from source (branch releases/2022/3)?

cmake -DCMAKE_BUILD_TYPE=Release -DENABLE_PYTHON=ON -DPYTHON_EXECUTABLE=<path to python> -DENABLE_INTEL_MYRIAD=ON -DENABLE_INTEL_MYRIAD_COMMON=ON

Also do not forget to set udev rules like so:

cat <<EOF > 97-myriad-usbboot.rules
SUBSYSTEM=="usb", ATTRS{idProduct}=="2150", ATTRS{idVendor}=="03e7", GROUP="users", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1"
SUBSYSTEM=="usb", ATTRS{idProduct}=="2485", ATTRS{idVendor}=="03e7", GROUP="users", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1"
SUBSYSTEM=="usb", ATTRS{idProduct}=="f63b", ATTRS{idVendor}=="03e7", GROUP="users", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1"
EOF

sudo cp 97-myriad-usbboot.rules /etc/udev/rules.d/
sudo udevadm control --reload-rules
sudo udevadm trigger
sudo ldconfig
amphancm commented 1 year ago

@DariaMityagina Hi! Thank you for your support.

Now, I've build branch releases/2022/3 that's MYRIAD Plugin Work fine.

benmark-myriad

and I've some problem about CPU and setupvars.sh

benmark-cpu-problem

openmodel-zoo-problem

Please Help!

DariaMityagina commented 1 year ago

@amphancm hello! I'm glad that you were able to work with Myriad plugin.

To solve the problem with the CPU plugin, please rebuild Openvino and add this line to the cmake command: -DENABLE_INTEL_CPU=ON

Also please try to set env var INSTALL_DIR to the location of Openvino. Or you can run setupvars.sh yourself, I guess.

Let me know if it works for you.

amphancm commented 1 year ago

@DariaMityagina Thank you

Now I can use Open model zoo with Raspberry pi 4B + Intel NCS2 Raspberrypi-openvino-intelncs2

But , cannot build ARM CPU Plugin yet.

DariaMityagina commented 1 year ago

@amphancm hello! Thanks for sharing your progress!

Can this issue be closed since myriad plugin seems to be working now?

LeviEnkon commented 10 months ago

Seems Cmake way to build Openvino is no longer possible by the end of 2023. I had tried over 10 times reinstall the raspberry pi os and use tried cmake Openvino on my raspberry pi but Openvino can not be import in python. I have to use pip is the only way that I can finally import Openvino in python. And now I'm facing the same trouble that when I tried to run a YOLOv8 model it shows me Device with "MYRIAD" name is not registered in the OpenVINO Runtime` It's there anyway to setup myriad plugin works with pip installed openvino?