I have an error when running on jupyter notebook
import cv2
import numpy as np
from matplotlib import pyplot as plt
%matplotlib inline
And here's the error:
---------------------------------------------------------------------------
ModuleNotFoundError Traceback (most recent call last)
~\AppData\Local\Temp/ipykernel_24728/2850105776.py in <module>
----> 1 import cv2
2 import numpy as np
3 from matplotlib import pyplot as plt
4 get_ipython().run_line_magic('matplotlib', 'inline')
ModuleNotFoundError: No module named 'cv2'
May I know how to solve it? Thanks
I was following this tutorial video on creating the project: https://www.youtube.com/watch?v=0-4p_QgrdbE Automatic Number Plate Recognition using Tensorflow and EasyOCR Full Course in 2 Hours | Python
CodePudding user response:
Make sure you have installed the module and that the version of python you are using is compatible with it. This site might be of help: Cannot find module cv2 when using OpenCV
CodePudding user response:
Welcome to SO, just install the package pip install opencv-python
or if you are using anaconda conda install -c conda-forge opencv