python 安装 cv2报错 conda install PackagesNotFoundError

问题描述:在vscode中利用conda 安装 cv2报错

报错如下:Collecting package metadata (current_repodata.json): done

Solving environment: unsuccessful initial attempt using frozen solve. Retrying with flexible solve.

Collecting package metadata (repodata.json): done

Solving environment: unsuccessful initial attempt using frozen solve. Retrying with flexible solve.

PackagesNotFoundError: The following packages are not available from current channels:

  • cv2
    Current channels:

解决

方案一

conda config --add channels conda-forge

conda config --add channels anaconda.org

conda config --remove-key channels

pip install opencv-python

  • 结果 :
    Successfully installed opencv-python-4.9.0.80
  • 总结:安装cv2 时使用如下命令
  • pip install opencv-python
  • 使用时:import cv2 as cv
相关推荐
郑州光合科技余经理31 分钟前
代码展示:PHP搭建海外版外卖系统源码解析
java·开发语言·前端·后端·系统架构·uni-app·php
feifeigo1231 小时前
matlab画图工具
开发语言·matlab
dustcell.1 小时前
haproxy七层代理
java·开发语言·前端
norlan_jame1 小时前
C-PHY与D-PHY差异
c语言·开发语言
多恩Stone2 小时前
【C++入门扫盲1】C++ 与 Python:类型、编译器/解释器与 CPU 的关系
开发语言·c++·人工智能·python·算法·3d·aigc
QQ4022054962 小时前
Python+django+vue3预制菜半成品配菜平台
开发语言·python·django
百锦再2 小时前
Django实现接口token检测的实现方案
数据库·python·django·sqlite·flask·fastapi·pip
QQ5110082852 小时前
python+springboot+django/flask的校园资料分享系统
spring boot·python·django·flask·node.js·php
QQ_19632884752 小时前
Python-flask框架西山区家政服务评价系统网站设计与开发-Pycharm django
python·pycharm·flask
遥遥江上月2 小时前
Node.js + Stagehand + Python 部署
开发语言·python·node.js