Python 如何检查安装的 Anaconda 是 32 位还是 64 位?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/26621846/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-19 00:46:24  来源:igfitidea点击:

How to check if the installed Anaconda is 32-bit or 64-bit?

pythonipython32bit-64bitwindows-7-x64conda

提问by Shashank Sawant

A few weeks ago, to dabble in IPython notebooks, I had downloaded and installed Anaconda from http://continuum.io/downloads. There was a problem in the installation (either because it was 32-bit or 64-bit — a detail I can't remember) which I solved but uninstalling my first attempt and installing the other version. Then I went about creating my notebooks with some practice problems.

几周前,为了涉足 IPython 笔记本,我从http://continuum.io/downloads下载并安装了 Anaconda 。安装中出现问题(因为它是 32 位或 64 位 - 我不记得这个细节)我解决了但卸载了我的第一次尝试并安装了另一个版本。然后我开始创建带有一些练习问题的笔记本。

Currently I can run ipython notebookin the command prompt and the notebooks run perfectly well. But the there's no mention of whether the system is 32-bit or 64-bit in the tree of notebooks (or in the tabs nearby).

目前我可以ipython notebook在命令提示符下运行,并且笔记本运行良好。但是在笔记本树(或附近的选项卡)中没有提到系统是 32 位还是 64 位。

I would usually sort such issues using the command prompt. But the commands conda --versionand ipython --versionjust yield the respective version numbers and not the information I am looking for.

我通常会使用命令提示符对此类问题进行排序。但是命令conda --versionipython --version只产生各自的版本号,而不是我正在寻找的信息。

My operating system is Win7x64but that hasn't prevented me from installing 32-bit softwares in past.

我的操作系统是,Win7x64但这并没有阻止我过去安装 32 位软件。

采纳答案by asmeurer

conda infohas this information. If you need to access it programmatically, use conda info --json.

conda info有这个信息。如果您需要以编程方式访问它,请使用conda info --json.

回答by monkut

Open a standard python console, and in the header it should tell you

打开一个标准的 python 控制台,在标题中它应该告诉你

Python 2.7.8 (default, Jun 30 2014, 16:03:49) [MSC v.1500 32 bit (Intel)] on win
32
Type "help", "copyright", "credits" or "license" for more information.
>>>

回答by Saurabh Shukla

conda --v. It displays the Conda version

康达--v。它显示 Conda 版本

回答by Erol Kalkan

For CentOS 6.7 and miniconda2:

对于 CentOS 6.7 和 miniconda2:

Type pythonand enter these commands:

键入python并输入以下命令:

import platform
print platform.architecture() 

In my case, it gives:

就我而言,它给出:

('32bit', '')