Installing Fast.ai in Alibaba Cloud GPU and Running It on Jupyter Notebook

Why GPU?

Fast.ai Features

Requirements

Launch Alibaba Cloud ECS Instance

Install Anaconda

curl –o https://repo.anaconda.com/archive/Anaconda3-5.3.0-Linux-x86_64.sh
sha256-sum Anaconda3-5.3.0-Linux-x86_64.sh
bash Anaconda3-5.3.0-Linux-x86_64.sh
Welcome to Anaconda3 5.3.0 (by Continuum Analytics, Inc.)In order to continue the installation process, please review the license
agreement.
Please, press ENTER to continue
Do you approve the license terms? [yes|no]
Anaconda3 will now be installed into this location:
/root/anaconda3
- Press ENTER to confirm the location
- Press CTRL-C to abort the installation
- Or specify a different location below
[/root/anaconda3] >>>
...
installation finished.
Do you wish the installer to prepend the Anaconda3 install location
to PATH in your /root/.bashrc ? [yes|no]
[no] >>>
Prepending PATH=/root/anaconda3/bin to PATH in /home/sammy/.bashrc
A backup will be made to: /root/.bashrc-anaconda3.bak
...
source ~/.bashrc
conda list
conda create --name fast.ai python=3
source activate fast.ai
(fast.ai) root@ubuntu:~$
source deactivate

Install Fast.ai

source activate fast.ai
conda install -c pytorch pytorch-nightly cuda92
conda install -c fast.ai torchvision-nightly
conda install -c fast.ai fast.ai

Trying Fast.ai with Jupyter Notebook Example

git clone https://github.com/fast.ai/fast.ai/tree/master/examples
jupyter notebook –-ip=0.0.0.0 –allow-root
http://(your-ip-address)/tree?token=f79ec772e0e53d30a221ecb18d447761e0f5a9d223c20175
ssh –L localhost:8888:localhost:8888 root@(your-ip-address)
http://localhost:8888/tree?token=f79ec772e0e53d30a221ecb18d447761e0f5a9d223c22017

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store