2019年10月30日 星期三

[GCP/ubuntu16.4/anaconda/jupyter]


vCPU:1
RAM:1.7G
容量:20G

1. SSH進去後安裝anaconda

cd /tmp //進入tmp放壓縮檔
sudo apt-get install bzip2 //安裝解壓縮程式
curl -O https://repo.anaconda.com/archive/Anaconda3-5.1.0-Linux-x86_64.sh //從網路上抓下安裝檔
bash Anaconda3-5.1.0-Linux-x86_64.sh //執行安裝檔
--
Do you accept the license terms? [yes|no]
[no] >>> yes
--
Do you wish the installer to prepend the Anaconda3 install location
to PATH in your /home/Jerry/.bashrc ? [yes|no]
[no] >>> yes
--
Do you wish to proceed with the installation of Microsoft VSCode? [yes|no]
>>> no

--
source ~/.bashrc //將command檔註冊
conda list //測試command


2. 啟動conda專案
conda create -n 你要取的名字 python=3.6
source activate 你剛剛取的名字

3. 打開jupyter開始打扣
註: 0.0.0.0 = 你的instance的external ip
jupyter notebook --ip=0.0.0.0 --port=8888 --no-browser &

4. 若要離開conda專案
source deactivate


5. jupyter調整
jupyter notebook list //查詢有哪些notebook
jupyter notebook stop 8888 //關掉某個notebook server

沒有留言:

張貼留言