Video: http://course.fast.ai/lessons/lesson1.html
Video timeline: http://wiki.fast.ai/index.php/Lesson_1_Timeline
Summary: http://wiki.fast.ai/index.php/Lesson_1 -----> Basically a numbered list of steps for the week!
Notes: http://wiki.fast.ai/index.php/Lesson_1_Notes
Lecture materials: https://github.com/fastai/courses/blob/master/deeplearning1/nbs/lesson1.ipynb
(Contains jupyter, where we type notes, code and display things)
(to get project files for the course)
(We will use their big computers)
(allows windows computer to interact with a unix computer such as AWS)
(so you can command AWS from your computer)
(tell amazon what we want)
(first-time login)
(bare essentials to get into your instance)
(Our files won't be stored on our personal computers)
(Setup up Kaggle)
(Poke around and run the code)
(Get practical, submit a squid or even an old scab, perfect it later)
Explanation:
jupyter notebook
conda install 'program name'
Steps:
jupyter notebook
If you have two versions of anaconda installed, you can reorder the folders that the computer searches for python in to pick and choose which one you use as default. To check which python:
python --version
To view the order that folders are searched for
env
vim ~/.bash_profile
source ~/.bash_profile
env
export PATH=/blah/blah:/gah
env
vim ~/.bash_profile
:wq
source ~/.bash_profile
env
env
TIP: if you ever want to interrupt some process that the terminal is running -> ctrl+c
Explanation:
git clone www.projectlocation.com
How to get git: Summary: https://help.github.com/articles/set-up-git/
git clone https://github.com/git/git
Make a cheat-sheet dump!
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew install wget
brew install tree
'tree'
is included along with 'wget'
cd
'proj'
. When naming things, spaces make it slow and difficult in terminal because spaces are used to separate commands, so use an underline instead of a space
mkdir proj
'proj'
and make a folder for deep learning 'dl'
mkdir dl
'dl'
cd dl
mkdir cheat_sheets
cd cheat_sheets
wget url
wget -O bash_sheet.pdf http://www.lsv.ens-cachan.fr/~fthire/teaching/2016-2017/programmation-1/cheatsheet/shell.pdf
wget -O bash_quick_sheet.pdf http://sites.tufts.edu/cbi/files/2013/01/linux_cheat_sheet.pdf
wget -O conda_cheat.pdf https://conda.io/docs/_downloads/conda-cheatsheet.pdf
wget -O git_sheet.pdf https://services.github.com/on-demand/downloads/github-git-cheat-sheet.pdf
wget -O jupyter_sheet.pdf https://www.cheatography.com/weidadeyue/cheat-sheets/jupyter-notebook/pdf/
wget -O python_sheet.pdf https://github.com/ehmatthes/pcc/releases/download/v1.0.0/beginners_python_cheat_sheet_pcc_all.pdf
wget -O tmux_sheet.pdf http://alvinalexander.com/downloads/linux/tmux-cheat-sheet.pdf
wget -O aws_alias_sheet.html http://wiki.fast.ai/index.php/Aws-alias
wget -O kaggle_sheet.html https://github.com/floydwch/kaggle-cli
wget -O tree_sheet.html http://mama.indstate.edu/users/ice/tree/tree.1.html
open blah_blah.pdf
pwd
) when removing files (rm 'file'
) because you might accidentally delete something importantExplanation:
Video: https://www.youtube.com/watch?v=8rjRfW4JM2I
Notes: http://wiki.fast.ai/index.php/AWS_install
There will be two types of AWS:
Install the free version (T2) of AWS
ls
cd 'folder name'
cd ..
pwd
git clone https://github.com/fastai/courses
Explanation:
Download and install:
Explanation:
Steps:
pip install --upgrade pip
pip install awscli
Explanation:
I think oregon is the best location for Aus at the moment. It's ages away, but I don't think the course AMI works for the amazon computers located in Sydney, which would be much quicker for us to use
Steps:
aws configure
us-west-2
text
'courses'
folder'setup'
folderbash setup_p2.sh
bash setup_t2.sh
Explanation:
Steps:
ssh -i /Users/yourdirectory/.ssh/aws-key-fast-ai.pem ubuntu@ec2-a-bunch-of-numbers.us-west-2.compute.amazonaws.com
ls
ls -a
sudo rm .bash_history
nvidia-smi
jupyter notebook
1+2
import theano
import keras
Description:
Steps:
/course/setup
source aws-alias.sh
alias
aws-get-t2
aws-get-p2
aws-start
aws-ip
aws-nb
aws-ssh
aws-stop
aws-get-t2
aws-start
aws-ip
aws-ssh
course/setup
foldersource aws-alias.sh
aws-get-t2
aws-ip
aws-ssh
Explanation:
Steps:
sudo apt-get install git
/home/ubuntu
). Ubuntu is the name of the version of the linux operating system that the amaon computers use
cd
git clone https://github.com/fastai/courses.git
sudo apt-get install tree
tree -d
Description:
Steps
pip install --upgrade pip
pip install kaggle-cli
kg config -g -u USERNAME -p PASSWORD -c dogs-vs-cats-redux-kernels-edition
sudo apt install unzip
/courses/deeplearning1/nbs
so that our data goes in the same folder as the rest of the projectmkdir data
cd data
wget http://www.platform.ai/files/dogscats.zip
unzip dogscats.zip
rm dogscats.zip
tree -d
tree -d --du
/courses/deeplearning1/nbs
so that our data goes in the same folder as the rest of the projectmkdir data
cd data
mkdir dogscats
kg download
unzip test.zip
unzip train.zip
rm test.zip
rm train.zip
/courses/deeplearning1/nbs/dogscats
pwd
'train'
and 'test'
folders are still there from when we downloaded them. They should be about 286,720 bytes and 757,760 bytes
ls -l
mkdir valid
mkdir sample
cd sample
mkdir train
mkdir valid
mkdir test
cd ..
cd ..
tree -d
'cats'
folder and a 'dogs'
folder (navigate with cd 'name'
and cd ..
, make with mkdir)tree --du
cp lesson1.ipynb lesson1_copy.ipynb
jupyter notebook
) and open deeplearning1/nbs/lesson1_copy.ipynb
cat vgg16.py
I'll put more here when I work out what it is
Need to do, but haven't looked into:
Description: No messing around. I have to go to bed and cats and dogs are running away!
git clone https://github.com/fastai/courses.git
pip install --upgrade pip
pip install kaggle-cli
kg config -g -u USERNAME -p PASSWORD -c dogs-vs-cats-redux-kernels-edition
courses/deeplearning1/nbs/dogs_cats_redux
'data'
folder, then inside that a 'redux'
folderkg download
sudo apt install unzip
sudo apt install tree
tree -d --du
'Action Plan'
tree -d --du
tree -d --du
sample/train
folder and some into the validation
folderkg submit submission1.csv -u USERNAME -p PASSWORD -c dogs-vs-cats-redux-kernels-edition -m any_message
Phew!
In [ ]: