python-cv2 module installation

  • 1. Automatic installation
    If the network environment is good:
pip install opencv-python
  • 2. Uninstall and install the specified version
    Uninstall opencv
pip uninstall opencv-python

Install the specified version of cv
The specified version is: 4.5.4.60

pip install opencv-python == 4.5.4.60
  • 3. Download and install the installation package Download the correct installation package
    from the official website
    for installation: You need to find the opencv-python version
    python3.6 corresponding to the python version, and the corresponding opencv-python version is 4.5.4.60
    insert image description here
    cp36: represents the python3.6 version
    Query the python version:
python

insert image description here

Under linux, you can install the suffix: manylinux1_x86_64.whl.
Windows can install the suffix win_amd64.
Download the file and install it on the command line

pip install xxxx.whl    #xxx为文件名
  • Install demo
    windows10 python3.11

insert image description here
download:
insert image description here
insert image description here

Guess you like

Origin blog.csdn.net/qq_41224270/article/details/131704415