卸载 opencv-contrib-python and opencv-python

1. pip - Python 2.x

strong@foreverstrong:~$ pip list | grep opencv
/usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/__init__.py:83: RequestsDependencyWarning: Old version of cryptography ([1, 2, 3]) may cause slowdown.
  warnings.warn(warning, RequestsDependencyWarning)
opencv-python                      3.4.1.15   
strong@foreverstrong:~$ 

2. pip3 - Python 3.x

strong@foreverstrong:~$ pip3 list | grep opencv
opencv-contrib-python (3.3.0.10)
opencv-python (3.4.0.12)
strong@foreverstrong:~$ 

3. 卸载 opencv-contrib-python

sudo pip3 uninstall opencv-contrib-python==3.3.0.10

strong@foreverstrong:~$ sudo pip3 uninstall opencv-contrib-python==3.3.0.10
[sudo] password for strong: 
The directory '/home/strong/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Uninstalling opencv-contrib-python-3.3.0.10:
  /usr/local/lib/python3.5/dist-packages/cv2/.libs/libQtCore-ba1dc80c.so.4.8.7
  /usr/local/lib/python3.5/dist-packages/cv2/.libs/libQtGui-6d0f14dd.so.4.8.7
  /usr/local/lib/python3.5/dist-packages/cv2/.libs/libQtTest-1183da5d.so.4.8.7
  /usr/local/lib/python3.5/dist-packages/cv2/.libs/libz-a147dcb0.so.1.2.3
  /usr/local/lib/python3.5/dist-packages/cv2/LICENSE-3RD-PARTY.txt
  /usr/local/lib/python3.5/dist-packages/cv2/LICENSE.txt
  /usr/local/lib/python3.5/dist-packages/cv2/__init__.py
  /usr/local/lib/python3.5/dist-packages/cv2/__pycache__/__init__.cpython-35.pyc
  /usr/local/lib/python3.5/dist-packages/cv2/cv2.cpython-35m-x86_64-linux-gnu.so
  /usr/local/lib/python3.5/dist-packages/opencv_contrib_python-3.3.0.10.dist-info/DESCRIPTION.rst
  /usr/local/lib/python3.5/dist-packages/opencv_contrib_python-3.3.0.10.dist-info/INSTALLER
  /usr/local/lib/python3.5/dist-packages/opencv_contrib_python-3.3.0.10.dist-info/METADATA
  /usr/local/lib/python3.5/dist-packages/opencv_contrib_python-3.3.0.10.dist-info/RECORD
  /usr/local/lib/python3.5/dist-packages/opencv_contrib_python-3.3.0.10.dist-info/WHEEL
  /usr/local/lib/python3.5/dist-packages/opencv_contrib_python-3.3.0.10.dist-info/metadata.json
  /usr/local/lib/python3.5/dist-packages/opencv_contrib_python-3.3.0.10.dist-info/top_level.txt
Proceed (y/n)? y
  Successfully uninstalled opencv-contrib-python-3.3.0.10
The directory '/home/strong/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
strong@foreverstrong:~$ 

4. 卸载 opencv-python

sudo pip3 uninstall opencv-python==3.4.0.12

strong@foreverstrong:~$ sudo pip3 uninstall opencv-python==3.4.0.12
The directory '/home/strong/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Uninstalling opencv-python-3.4.0.12:
  /usr/local/lib/python3.5/dist-packages/cv2/.libs/libavcodec-7625dabe.so.58.6.103
  /usr/local/lib/python3.5/dist-packages/cv2/.libs/libavformat-d3ca1b40.so.58.3.100
  /usr/local/lib/python3.5/dist-packages/cv2/.libs/libavutil-eaec640f.so.56.5.100
  /usr/local/lib/python3.5/dist-packages/cv2/.libs/libswresample-81cb7b3e.so.3.0.101
  /usr/local/lib/python3.5/dist-packages/cv2/.libs/libswscale-bc8d848b.so.5.0.101
  /usr/local/lib/python3.5/dist-packages/cv2/data/__init__.py
  /usr/local/lib/python3.5/dist-packages/cv2/data/__pycache__/__init__.cpython-35.pyc
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_eye.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_eye_tree_eyeglasses.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_frontalcatface.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_frontalcatface_extended.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_frontalface_alt.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_frontalface_alt2.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_frontalface_alt_tree.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_frontalface_default.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_fullbody.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_lefteye_2splits.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_licence_plate_rus_16stages.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_lowerbody.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_profileface.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_righteye_2splits.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_russian_plate_number.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_smile.xml
  /usr/local/lib/python3.5/dist-packages/cv2/data/haarcascade_upperbody.xml
  /usr/local/lib/python3.5/dist-packages/opencv_python-3.4.0.12.dist-info/DESCRIPTION.rst
  /usr/local/lib/python3.5/dist-packages/opencv_python-3.4.0.12.dist-info/INSTALLER
  /usr/local/lib/python3.5/dist-packages/opencv_python-3.4.0.12.dist-info/METADATA
  /usr/local/lib/python3.5/dist-packages/opencv_python-3.4.0.12.dist-info/RECORD
  /usr/local/lib/python3.5/dist-packages/opencv_python-3.4.0.12.dist-info/WHEEL
  /usr/local/lib/python3.5/dist-packages/opencv_python-3.4.0.12.dist-info/metadata.json
  /usr/local/lib/python3.5/dist-packages/opencv_python-3.4.0.12.dist-info/top_level.txt
Proceed (y/n)? y
  Successfully uninstalled opencv-python-3.4.0.12
The directory '/home/strong/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
strong@foreverstrong:~$

5. pip3 list | grep opencv

strong@foreverstrong:~$ pip3 list | grep opencv
strong@foreverstrong:~$ 

References

[1] Yongqiang Cheng, https://yongqiang.blog.csdn.net/

  • 5
    点赞
  • 16
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

Yongqiang Cheng

梦想不是浮躁,而是沉淀和积累。

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值