官术网_书友最值得收藏!

Installing on Linux

To install the distribution, follow these steps given as follows:

  1. First, download the latest installer build from https://www.anaconda.com/download/#linux
  2. Then, in the Linux Terminal, pass this bash command:
$ bash Anaconda-latest-Linux-x86_64.sh
  1. Follow the prompts in the terminal and it will begin installing. Once done, you will be asked if you want to allow Conda to be auto-initialized with a .bashrc entry. I recommend choosing N and activating it manually when needed, just in case you decide to have multiple versions of Conda on your system. In this case, you can launch the Conda prompt by using the following command: 
$ source /{anaconda3_dir}/bin/activate

This is will source the Conda activate shell script and call it to activate the base environment, which is the default Anaconda Python bundle. Adding new environments will be discussed in the following section on how to install specific libraries. At this point, passing the Python command will open an interactive shell where you can execute Python code line-by-line, as shown in the following code snippet:

(base) $ Python
Python 3.7.0 (default, Jun 28 2018, 13:15:42)
[GCC 7.2.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import numpy
>>> numpy.random.random(10)
array([0.48489815, 0.80944492, 0.89740441, 0.93031125, 0.71774534,
0.63817451, 0.93231809, 0.75820457, 0.17550135, 0.62126858])

Alternatively, you can execute the code in a stored Python script by using the following command:

(base) $ Python script.py
主站蜘蛛池模板: 仙游县| 叶城县| 西吉县| 金寨县| 永和县| 明星| 固安县| 丰宁| 个旧市| 弥渡县| 云阳县| 林州市| 荆门市| 泊头市| 平南县| 凭祥市| 麟游县| 平罗县| 明星| 巨野县| 沈阳市| 莆田市| 商南县| 比如县| 磐安县| 六盘水市| 古浪县| 繁峙县| 曲麻莱县| 白城市| 乐昌市| 博罗县| 游戏| 阳朔县| 怀化市| 阳山县| 城口县| 蒲城县| 梧州市| 京山县| 黎川县|