适用于 Windows、matplotlib 和 opencv 的 Python

标签 python windows matplotlib opencv-python

我已经尝试为 Windows 安装 Python3.7。之后我尝试安装 numpy 等软件包,一切正常。但是,当我尝试安装matplotlib时,发现如下错误:

 * The following required packages can not be built:
                            * freetype, png
                            * Please check http://gnuwin32.sourceforge.net/packa
                            * ges/freetype.htm for instructions to install
                            * freetype
                            * Please check http://gnuwin32.sourceforge.net/packa
                            * ges/libpng.htm for instructions to install png

然后当我尝试安装 opencv-python 时,出现以下错误:

 Could not find a version that satisfies the requirement opencv-python (from versions: )
No matching distribution found for opencv-python

我该如何解决这些问题?

最佳答案

Python 3.7 刚刚在 2 天前发布,Python 3.7 还不支持很多模块。如果您真的不需要 Python 3.7,请降级到 Python 3.6 以下载包。

或者

下载 Anaconda 5.2 以在 Python 3.6 中使用 matplotlibopencv。这是适用于 Windows 的 Anaconda 下载链接:[链接] ( https://www.anaconda.com/download/#windows )

我建议下载 Anaconda 以同时使用 matplotlibopencv

关于适用于 Windows、matplotlib 和 opencv 的 Python,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51116016/

相关文章:

python - Flask 网站 -- 500 内部服务器错误

python - 修复 Excel 文件

c - windows下EOF的值

php - IIS PHP 使用 Windows 身份验证连接到 MSSQL

.net - 有没有办法通过 LAN 缓存和分发 Visual Studio 更新?

python - Matplotlib散点图未能显示所有图例(有些图例丢失)

Python print 语句在参数之间添加空格

python - 使用 Visual Studio Code 在 Python 中逐步调试导入的模块

Python3 : matplotlib. pyplot.plot_date() 日期标签溢出

python - 在 matplotlib 中添加径向轴标签