Pycharm未运行Anaconda环境

时间:2019-05-26 00:14:40

标签: pycharm anaconda

我正在使用Anaconda环境以及Pandas,Tensorflow,Keras和Matplotlib。

当我在Anaconda Prompt中运行代码时,它可以正常工作,但是当我尝试在Pycharm中运行代码时,会收到一条错误消息,提示它找不到依赖项。

错误消息

<scripts-section>

我选择了与Pycharm中的项目解释器相同的环境。我在列表中看到了所需的软件包。

我不明白我在这里想念什么。

项目的口译包

 File "<input>", line 1, in <module>
  File "C:\Program Files\JetBrains\PyCharm Community Edition 2018.2.3\helpers\pydev\_pydev_bundle\pydev_umd.py", line 197, in runfile
    pydev_imports.execfile(filename, global_vars, local_vars)  # execute the script
  File "C:\Program Files\JetBrains\PyCharm Community Edition 2018.2.3\helpers\pydev\_pydev_imps\_pydev_execfile.py", line 18, in execfile
    exec(compile(contents+"\n", file, 'exec'), glob, loc)
  File "C:/Users/Lia love/TestAi/Test1.py", line 1, in <module>
    import pandas as pd
  File "C:\Program Files\JetBrains\PyCharm Community Edition 2018.2.3\helpers\pydev\_pydev_bundle\pydev_import_hook.py", line 20, in do_import
    module = self._system_import(name, *args, **kwargs)
  File "D:\Anaconda\envs\scikit_env\lib\site-packages\pandas\__init__.py", line 19, in <module>
    "Missing required dependencies {0}".format(missing_dependencies))
ImportError: Missing required dependencies ['numpy']

谢谢!

1 个答案:

答案 0 :(得分:0)

尝试安装最新的2019.1.3 RC build。它包含许多有关PyCharm中的Anaconda支持的修复程序(例如https://youtrack.jetbrains.com/issue/PY-35141)。 “缺少必需的依赖项”的问题也应该在那里解决。