This is a small series of machine learning Jupyter Notebooks targeted to a 12-15 year old audience. In this series we start with a single pixel containing red, green, and blue color components, and we train a neural network to turn the color of the pixel into color names, step by step.
There is more detail in the Part00_Intro.md file.
This repo contains Jupyter notebooks, which are interactive pages containing text and Python code you can run and modify. To use a Jupyter notebook you need to run a Python program to create the notebook and open a web page to it.
If you have not set up your machine environment yet, follow the instructions in the "getting started" section below.
To run the Jupyter notebook:
- (If you don't already have a console open) Open a Windows console: Windows+R (to open the Run box), then type
cmd
and press Enter. - Change location to that folder:
cd c:\ColorMatching
- Run the command:
jupyter notebook
. A web page should open showing the contents of the folder. You can then click on the various lessons and text files. They are ordered Part00, Part01, etc. - Jupyter notebooks have text sections and code "cells." You can scan through the cells by clicking the Run button at the top. Be patient when running code, however - sometimes it can be slow especially the first time you run something. Also, a whole page is like one big Python program, so you need to be sure to run the code at the top first before trying to run code at the bottom.
- Install Git from https://git-scm.com/download/win (for Windows), or https://git-scm.com/download for other operating systems.
- Install Python 3.6 (but not 3.7!) from https://www.python.org/downloads/ . Use the 64-bit version.
- NOTE: We found that we had to uninstall Python 3.7 since TensorFlow currently needs only 3.6. We're not using Python virtual environments or Anaconda in these instructions.
- Open a Windows console: Windows+R (to open the Run box), then type
cmd
and press Enter. - Create a new folder:
mkdir c:\ColorMatching
- Move to that folder:
cd c:\ColorMatching
- Clone the Git repo to your new folder:
git clone https://github.com/erikma/ColorMatching .
- Type
setup
and press Enter.
To pull the latest changes from GitHub:
- (If you don't already have a console open) Open a Windows console: Windows+R (to open the Run box), then type
cmd
and press Enter. - Change location to that folder:
cd c:\ColorMatching
- Pull down the latest code:
git pull
As of creation of this repo in March, 2019, Microsoft Notebooks was in a very unstable state, but when it was running correctly it was the best experience.
Google Colab is very smooth and made it easy to add GPU and TPU turbo-charging to the training portions. Only problem was that I could not get the color mixer Display(HTML())
to show the color properly, and that experience is core to the notebook series.