【问题标题】:How to install NumPy on PyCharm?如何在 PyCharm 上安装 NumPy?
【发布时间】:2020-09-08 02:51:50
【问题描述】:

我已经在 cmd 上安装了 NumPy 并且正在空闲运行,但在 PyCharm 中,它说:

error: Microsoft Visual C++ 14.0 is required. Get it with "Build Tools for Visual Studio": https://visualstudio.microsoft.com/downloads`

proposed solution

**Try to run this command from the system terminal. Make sure that you use the correct version of 'pip' installed for your Python interpreter located at 'C:\Users\ACER\This PC\Downloads\Video\pycharm\venv\Scripts\python.exe'.**

【问题讨论】:

  • 你试过安装第一行提到的Microsoft Visual C++吗?

标签: python numpy pycharm installation-package


【解决方案1】:

您的虚拟环境是否使用 numpy 具有二进制轮子的 Python 版本? As of this post,表示 Python 3.5-3.8、32 位或 64 位 Intel。

如果是(您可以通过运行 Python REPL 来检查,即venv\Scripts\python),您可以尝试升级打包工具链并重新安装。在命令行中运行以下命令(从错误中命名的pycharm 目录):

venv\Scripts\python -m pip install -U pip setuptools wheel
venv\Scripts\python -m pip install -U numpy

【讨论】:

    【解决方案2】:

    我在终端中使用了这个命令,它可以工作 venv\Scripts\python -m pip install -U pip setuptools wheel venv\Scripts\python -m pip install -U

    【讨论】:

      猜你喜欢
      • 2020-07-30
      • 1970-01-01
      • 2014-01-31
      • 1970-01-01
      • 2018-11-10
      • 2021-02-26
      • 1970-01-01
      • 2020-01-07
      • 2020-10-26
      相关资源
      最近更新 更多