0
votes

import cv2

ImportError Traceback (most recent call last) in ----> 1 import cv2

~\Anaconda3\lib\site-packages\cv2__init__.py in 3 import sys 4 ----> 5 from .cv2 import * 6 from .data import * 7

ImportError: DLL load failed: The specified module could not be found

2
Can you mention on which system you installed it and what was the command you used ?Eyshika

2 Answers

1
votes

Looks like you are using Anaconda. If so don't use pip as it can break your environment, use conda.

You can try by first going to "anaconda-prompt" using windows search and then run the command as below:

conda install -c conda-forge opencv

or any other from https://anaconda.org/conda-forge/opencv.

0
votes

Maybe you can uninstall and install opencv. This usually happens when you download package at a different file location or the package itself is not installed properly. I suggest using this:

1.pip install opencv-python

or if you need the full module (cnn, face analysis, shape and etc)

2.pip install opencv-python-contrib