LoginSignup
1
2

More than 5 years have passed since last update.

Jupyter notebookのインストール

Last updated at Posted at 2017-11-07

環境

  • Ubuntu 16.04

手順

インストール

$ pip3 install jupyter --user
  • .vimrcに以下を追加
export PATH=$HOME/.local/bin:$PATH
export PYTHONPATH=$HOME/.local/lib/python3.5/site-packages
  • .bashrc再読み込み
$ source ~/.bashrc

設定ファイル生成

$ jupyter notebook --generate-config
  • ~/.jupyter/jupyter_notebook_config.py が生成

設定ファイル(jupyter_notebook_config.py)変更

1. 本環境はサーバで別PCからアクセスするので、本環境内のWebブラウザでのJupyter起動を禁止する

*  c.NotebookApp.open_browser = False

2. ポート番号の設定

* c.NotebookApp.port = 9999

3. ワーキングディレクトリの指定

* c.NotebookApp.notebook_dir = u'/home/user/jupyter'

4. ログインパスワードの設定

  • 以下のコマンドで生成、「sha1~」をコピーし、「c.NotebookApp.password」に貼り付ける
$ ipython
In [1]: from notebook.auth import passwd
In [2]: passwd()
・・・
Out[2]: 'sha1:~~'
Out[3]: exit

5. IPアドレスの設定

* c.NotebookApp.ip = '~~'

起動

$ jupyter notebook
1
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
2