在VS2017中使用conda环境 [英] Use conda environment in VS2017

查看:1003
本文介绍了在VS2017中使用conda环境的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在VS2017中使用conda虚拟环境,但出现错误,它无法在所选路径中标识虚拟环境.下面的屏幕截图不是我的,而是来自此 SO问题,这很相似,但不能解决我的问题.我的路径是C:\Users\USERNAME\.conda\envs\tensorflow.

I want to use a conda virtual environment with VS2017, but I get the error that it could not identify a virtual environment in the selected path. The screenshot below is not mine, but it's from this SO question, which is similar but does not solve my problem. My path is C:\Users\USERNAME\.conda\envs\tensorflow.

我已经使用Visual Studio 2017安装程序安装了python 3.6和anaconda 4.3.0.然后我按照SO上的步骤操作,以为tensorflow创建python 3.5环境.

I have installed python 3.6 and anaconda 4.3.0 using the Visual Studio 2017 installer. Then I've followed the steps on SO to create a python 3.5 environment for tensorflow.

我的猜测是Visual Studio无法识别python 3.5的安装,但是我不确定在不弄乱我的系统的情况下解决该问题的最佳方法是什么.

My guess is that Visual Studio doesn't recognize the python 3.5 installation, but I'm not sure what would be the best way to solve that without making a mess of my system.

有一个 python诊断信息的要点.

There is a similar SO question, but it has no responses. Here is a gist of my python diagnostic info from VS 2017.

推荐答案

糟糕,事实证明,这 SO答案毕竟是正确的.在Visual Studio中创建自定义环境后,它便可以工作.

Oops, it turns out that this SO answer is correct after all. It works after creating a custom environment within Visual Studio.

这篇关于在VS2017中使用conda环境的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆