Jupyter Notebook on Raspberry Pi
Step 1: Installation
Type the following into the terminal:
sudo su -
apt-get update
apt-get install python3-matplotlib
apt-get install python3-scipy
pip3 install --upgrade pip
reboot
sudo pip3 install jupyter
The Raspberry Pi normally uses an memory card, called an SD card, just like the ones you might use in your digital camera. They don’t have as much space as a normal computer. Issue the following command to clean up the software packages that were downloaded in order to update your Raspberry Pi.
sudo apt-get clean
Recent versions of Raspian replaced the Epiphany web browser with Chromium (an open source version of the popular Chrome browser). Epiphany is much lighter than the heavier Chromium and works better with the tiny Raspberry Pi Zero. To set it as the default browser to be used later for the IPython notebooks issue the following command:
sudo update-alternatives --config x-www-browser
sudo reboot
Step 2: Testing
Start IPython by issuing the following command from the Terminal:
jupyter-notebook
Step 3: generate the config files
jupyter notebook --generate-config
配置文件保存在 /home/pi/.jupyter/jupyter_notebook_config.py文件夹下
Step 4: set password of the notebook
jupyter notebook password
Step 5:配置远程登陆
打开配置文件,设置下面几个选项,把注释符#去掉
-
c.NotebookApp.ip = '0.0.0.0'
-
c.NotebookApp.port = 8888 #远程访问端口
-
c.NotebookApp.open_browser = False
最后:Start IPython by issuing the following command from the Terminal:
jupyter-notebook