0

I installed Anaconda and install Jupyter Notebook in Anaconda Navigator by following this tutorial: Install Anaconda on Mac, and then I set up a new environment called "Computer Vision" the programming language is Python 2.7, and then I installed libopencv, opencv, py-opencv. I want to test if OpenCV has been installed successfully, so I only write one line code

import opencv

And the error says

---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
<ipython-input-2-140d3f9c9adb> in <module>()
----> 1 import opencv

ImportError: No module named opencv

I do not understand why this happens, I am sure I launch Jupyter Notebook after I installed the OpenCV module. I also try to use Python3.7 but it still not work.

Thank you for taking care of this question.

2

1 Answer 1

3

Opencv is imported via the line import cv2, instead of import opencv. This is true in both Python 2 and 3.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.