- conda中创建新环境
- 按照requirements.txt安装包,遇到错误的先删掉
安装lap和lapsolver时遇到错误
ERROR: Could not find a version that satisfies the requirement pytest-runner (from versions: none)
ERROR: No matching distribution found for pytest-runner
lap用conda清华源安装了,lapsolver从pypi网站下载whl的win32版本pip安装好了
4. import sacred 出错
ImportError: Failed to initialize: Bad git executable.
The git executable must be specified in one of the following ways:
- be included in your $PATH
- be set via $GIT_PYTHON_GIT_EXECUTABLE
- explicitly set via git.refresh()
All git commands will error until this is rectified.
This initial warning can be silenced or aggravated in the future by setting the
$GIT_PYTHON_REFRESH environment variable. Use one of the following values:
- quiet|q|silence|s|none|n|0: for no warning or exception
- warn|w|warning|1: for a printed warning
- error|e|raise|r|2: for a raised exception
Example:
export GIT_PYTHON_REFRESH=quiet
下载git安装,在 https://npm.taobao.org/mirrors/git-for-windows/ 下载更快,官网很慢,一直next安装好了之后,打开git bash配置
在虚拟环境中运行这一指令让python调用git
set GIT_PYTHON_GIT_EXECUTABLE=C:\Program Files\Git\cmd\git.exe
这个问题就能解决
6. virtualenv中的pip install -e .
等价于python setup.py develop
,用这句install tracktor
7. test_tracktor.py就可以运行了
8. 用pycharm直接运行的话,运行根目录不对。
在run/run/edit 设置里 configures/working directory 更改目录