Anaconda/conda/python/Windows:如何启动和激活conda环境



我通过Anaconda安装了Python 3.5(3.5.6(,现在我希望能够使用Python 3.7,将3.5作为默认值(python "insert script name"将在命令行上运行(。我命令电脑启动它,但它不工作。

Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.
PS C:WINDOWSsystem32> conda create --name seiska python=3.7
WARNING: A space was detected in your requested environment path
'C:Program FilesAnaconda3envsseiska'
Spaces in paths can sometimes be problematic.
Solving environment: done
## Package Plan ##
environment location: C:Program FilesAnaconda3envsseiska
added / updated specs:
- python=3.7

The following NEW packages will be INSTALLED:
ca-certificates: 2018.03.07-0
certifi:         2018.10.15-py37_0
openssl:         1.1.1a-he774522_0
pip:             18.1-py37_0
python:          3.7.1-he44a216_5
setuptools:      40.6.2-py37_0
vc:              14.1-h0510ff6_4
vs2015_runtime:  14.15.26706-h3a45250_0
wheel:           0.32.3-py37_0
wincertstore:    0.2-py37_0
Proceed ([y]/n)? y
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
#
# To activate this environment, use:
# > activate seiska
#
# To deactivate an active environment, use:
# > deactivate
#
# * for power-users using bash, you must source
#
PS C:WINDOWSsystem32> activate seiska
PS C:WINDOWSsystem32> python
Python 3.5.6 |Anaconda 4.2.0 (64-bit)| (default, Aug 26 2018, 16:05:27) [MSC v.1900 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>>

在「开始」菜单中,您必须打开"Anaconda提示符",这与正常的"命令提示符"不同。你的环境从那里被激活。然后执行activate <env-name>

最新更新