Intel® Distribution of OpenVINO™ Toolkit
Community assistance about the Intel® Distribution of OpenVINO™ toolkit, OpenCV, and all aspects of computer vision-related on Intel® platforms.
6392 Discussions

ModuleNotFoundError: No module named 'openvino'

tangweijie_twj
Beginner
2,575 Views

I'm trying to run a signal classification and recognition demo on OpenVINO. So I tried the 'sound_classification_demo.py'. I ran the installation correctly and I've already transferred the IR documents so it means that the OV environment is correct. However, when I tried to run the sound classification demo python, this error came up.

ModuleNotFoundError: No module named 'openvino'

My running environment:

MacOS 11.0.1

OpenVINO 2021.2.185

python 3.8

I've attached the screenshot pic of my terminal at the end. Please help me with this problem.

Thanks,

Jerry

0 Kudos
8 Replies
Syamimi_Intel
Moderator
2,555 Views

Hi Weijie Tang,

 

Thank you for reaching out. We are currently investigate. However, I need to understand more regarding your workaround.

Firstly, what do you mean by "transferred the IR documents so it means that the OV environment is correct." ?

 

Did you successfully convert the model into IR (.xml & .bin) format using OpenVINO Model Optimizer ?

Could you share your command of the conversion and also how you running the demo for us to test on our side.

 

Meanwhile, please be noted that python version that supported by OpenVINO for MacOS is only python 3.6 and 3.7 version.

https://docs.openvinotoolkit.org/latest/openvino_docs_install_guides_installing_openvino_macos.html

 

Regards,

Syamimi

0 Kudos
tangweijie_twj
Beginner
2,541 Views

Hi Syamimi,

Thank you for replying me. I converted the model to IR documents with your guys' help. Thanks again. I mean that my settings of OpenVINO is correct because I read some posts saying that the problem' No module named XXX' is owing to OpenVINO environment's uninitialized.

0 Kudos
Syamimi_Intel
Moderator
2,471 Views

Hi Weijie Tang,

 

Thank you for waiting. I have validated the Sound Classification Python demo from my side and it is working fine.

 

You can try to run the Sound Classification Python demo using aclnet model and please ensure that you have set up environment variables every time you open a new terminal.

 

Also, if you are not using python 3.6 or 3.7, then have a chance to try it.

 

Regards,

Syamimi

 

0 Kudos
tangweijie_twj
Beginner
2,454 Views

Thank you Syamimi!

Of course I set up the environment variables every time I open the terminal. However, I never close my terminal which i use to run OpenVINO. I'll try for more times.

And I think that MacOS contains both Python2.7 and Python3.6,3.7. 

I'm wondering if the openvino2021.2.185 could fix MacOS11.0 well because it's a new system just released and based ARM platform.

Thank you for replying!

Jerry Tang

0 Kudos
Syamimi_Intel
Moderator
2,439 Views

Hi Weijie Tang,

MacOS 11 is not currently validated for OpenVINO but you can have a try by checking Software Requirements to run the demos:

  1. Please check your python path that you set to the OpenVino. You needs to set Python 3.6 or 3.7 as a primary Python version.
  2. Ensure you are using CMake 3.10 or higher
  3. Apple Xcode* Command Line Tools

 

Regards,

Syamimi

 

0 Kudos
tangweijie_twj
Beginner
2,417 Views

Hi Syamimi

I have set the OpenVINO environment permanently but there is still the error, so I guess it's not the problem of my OpenVINO environment.

  1. According to what you replied, I checked my primary version. I typed python3 in the terminal and it came out" Python 3.8.2". I'm not sure if my primary python version is 3.8 because I imported the whole python3 package(containing 3.6, 3.7, 3.8) to OpenVINO when I installed it. By the way, there were no errors regarding to python version.
  2. My CMake version is 3.20
  3. I have just installed Apple Xcode* Command Line Tools but it still has the same error.

Looking forward to your prompt reply.

Regards,

Tang

0 Kudos
Syamimi_Intel
Moderator
2,387 Views

Hi Weijie Tang,

Sorry for your inconvenience. It confusing me because your installation is not following the Software Requirements.

Currently, OpenVINO 2021.2.185 for MacOS has not been officially validated for MacOS 11.0.1 and Python 3.8.

 

For your information, I am using macOS 10.15 and Python 3.7.9 on my machine and everything works well.


However, you can try to reinstall the OpenVINO and ensure you are following the installation steps and make sure you meet the Software Requirements needed.

 

Refer to this link for OpenVINO installation:

https://docs.openvinotoolkit.org/latest/openvino_docs_install_guides_installing_openvino_macos.html

 

Regards,

Syamimi



0 Kudos
Syamimi_Intel
Moderator
2,346 Views

Hi Weijie Tang,

Thank you for your question. If you need any additional information from Intel, please submit a new question as this thread is no longer being monitored.


Regards,

Syamimi


0 Kudos
Reply