简体   繁体   English

将GitHub python软件包安装到Spyder的Anaconda中

[英]Installing GitHub python package into Anaconda, Spyder

I am trying to install https://github.com/esiivola/GPYgradients/tree/grad_obs.git and use it in Anaconda's spyder. 我正在尝试安装https://github.com/esiivola/GPYgradients/tree/grad_obs.git并将其用于Anaconda的spyder中。 I want this version of GPy to overwrite what I install when running "pip install GPy". 我希望此版本的GPy覆盖我在运行“ pip install GPy”时安装的内容。 I have tried "!pip install -e git+ https://github.com/esiivola/GPYgradients/tree/grad_obs.git#egg=GPyGradient " withing spyder. 我已经尝试过将“!pip install -e git + https://github.com/esiivola/GPYgradients/tree/grad_obs.git#egg=GPyGradient ”和spyder一起使用。 It gives me an error: Command "git clone -q https://github.com/esiivola/GPYgradients/tree/grad_obs.git C:\\Users...\\src\\gpygradient" failed with error code 128 in None. 它给了我一个错误:命令“ git clone -q https://github.com/esiivola/GPYgradients/tree/grad_obs.git C:\\ Users ... \\ src \\ gpygradient”失败,错误代码为128。 What am I doing wrong? 我究竟做错了什么?

You can use the tar ball: 您可以使用tar球:

pip install https://github.com/<user>/<repo>/archive/master.tar.gz

Instead of master, you can give any other branch or release tag. 除了母版,您还可以提供其他任何分支或发行标签。

Correct URL is https://$HOST/repo@commit#egg=module . 正确的URL是https://$HOST/repo@commit#egg=module repository is /esiivola/GPYgradients.git , commit is grad_obs which is a branch (could be a tag or a commit ID). repository/esiivola/GPYgradients.git ,提交是grad_obs ,它是一个分支(可以是标记或提交ID)。

pip install -e git+https://github.com/esiivola/GPYgradients.git@grad_obs#egg=GPyGradient

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM