Applying Deep Learning
- Networks learn painting styles and can apply it to any other image
- Use DL to navigate through traffic efficently
- MIT simulation of highway traffic
- Single car run by trainable, neural network.
- Task: Drive as fast as possible, learns by trial and error.
- Takes input, process through hidden layer, outputs
- Input = state
- Cars around it
- State is updated at each time step
- Hidden layers find patterns and learn from them. More will be revealed.
- Output = How fast car is driving
- Input = state
- This is reinforcement learning. Neural network experiments with trial and error and favors any decision that improves car’s speed.
- Another example of reinforcement learning.
- AI can learn to play FlabbyBird with no knowledge of its mechanics.
- Example of console output while AI plays FB
TIMESTEP 5880 / STATE observe / EPSILON 0.0001 / ACTION 0 / REWARD 0.1 / Q_MAX 1.266485e+01 TIMESTEP 5881 / STATE observe / EPSILON 0.0001 / ACTION 1 / REWARD 0.1 / Q_MAX 1.278625e+01
- Question: Is there a FlappyBird API the neural net is tapped into? Or is it actually assessing the visuals?
- Answer: … input is raw pixels and … output is a value function estimating future rewards.
- Anaconda is a python env and package manager aimed at supporting data science projects.
condadistribution comes with a ton of packages.
minicondais a lighter alternative.
- Does not exclusively manage python packages.
- Packages, including python version, are scoped to conda environment
- Share conda envs by exporting env yaml
conda env export > environment.yaml
conda env create -f environment.yaml
- Include an
env.yamlin public repos, or use a pip freeze file for those without anaconda
- Web app to store code, videos, data, notes
- Method to share data based projects growing in popularity
- Inspired by Donald Knuth’s Literate Programming
The practitioner of literate programming can be regarded as an essayist, whose main concern is with exposition and excellence of style. Instead of imagining that our main task is to instruct a computer what to do, let us concentrate rather on explaining to human beings what we want a computer to do.
nb_condalets you manage conda environments from Jupyter
- TIL you can highlight math in markdown files w/ $ offsets: $2 + 2 = 4$ Even prettier, do multiline w/ $$:
- Break command out of notebook code blocks with keywords prefaced w/
- For example,
%timeitwill run metrics on a function,
%matplotlibcan be used to embed a visualization and
%pdbturns on debug mode
- Notebooks are just JSON w/ an
- Makes it easy to convert them to other formats
nbconvertis the utility to do it
- Create slideshows out of notebooks, too