SCIP Python安装问题Windows带有pip [英] SCIP Python Installation Issue Windows with pip
问题描述
您好社区/开发人员,
我目前正在尝试使用python安装SCIP,发现有Windows支持和基于
I am currently trying to install SCIP with python and found that there is Windows Support and a pip installer based on https://github.com/SCIP-Interfaces/PySCIPOpt/blob/master/INSTALL.md.
尽管如此,我仍然遇到无法打开包含文件"的问题
Nevertheless I run into a problem "Cannot open include file"
下面是我为完成此步骤而执行的操作的列表.
Below is a list of the things I performed to get to this step.
- 下载Python Anaconda 2.7 64位
- 按原样安装所有复选框
- 下载PyCharm社区版
- 单击64位桌面链接,然后与.py复选框关联
- 打开CMD>写:easy_install -U pip
- 下载适用于Python 2.7的Visual C ++编译器
- 设置文件夹结构和下载的头文件
-
CMD> pip install pyscipopt导致错误:
- Download Python Anaconda 2.7 64 bit
- Install with all checkboxes as they are
- Download PyCharm Community edition
- Click 64 bit desktop link, and associate with .py checkboxes
- Open CMD > write: easy_install -U pip
- Download Visual C++ Compiler for Python 2.7
- Setup folder structure and downloaded header files
CMD > pip install pyscipopt leads to error:
C:\ Users \ UserName \ Downloads \ SCIPOPTDIR \ include \ scip/def.h(32):致命错误C1083:无法打开包含文件:'stdint.h':没有此类文件或目录 错误:命令"C:\ Users \ UserName \ AppData \ Local \ Programs \ Common \ Microsoft \ Visual C ++ for Python \ 9.0 \ VC \ Bin \ cl.exe"失败,退出状态为2
C:\Users\UserName\Downloads\SCIPOPTDIR\include\scip/def.h(32) : fatal error C1083: Cannot open include file: 'stdint.h': No such file or directory error: command 'C:\Users\UserName\AppData\Local\Programs\Common\Microsoft\Visual C++ for Python\9.0\VC\Bin\cl.exe' failed with exit status 2
我的环境变量和文件夹目录可以在这里找到: http://imgur.com/a/mJRva
My environment variables and folder directory can be found here: http://imgur.com/a/mJRva
非常感谢您的帮助, 亲切的问候
Help is very much appreciated, Kind regards
推荐答案
好的,我知道了.我需要
Alright, I figured it out. I needed to
(1)安装Python 3.6而不是Python 2.7(均为Anaconda) (2)之后点子安装成功了 (3)我将库文件移到了lib文件夹中 (4)现在我可以执行示例.
(1) Install Python 3.6 instead of Python 2.7 (both Anaconda) (2) Afterwards pip installation worked (3) I moved the library files in the lib folder (4) Now I can execute the examples.
有趣的是,尽管代码可以正常工作(虽然我认为这是Pycharm/scipy的错误吗?),但是我仍然得到未解决的参考错误.链接至图片:
Interestingly, I get an unresolved reference error although the code works fine (I assume this is a bug of Pycharm/scipy?) Link to picture: https://www.dropbox.com/s/d8pf6dkwuz9cwto/scip_python.png?dl=0
这篇关于SCIP Python安装问题Windows带有pip的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!