Magic around New Year’s Eve

This magical time of the year, Simon’s craziest, most daring dreams come true! First, his guru from the New York University Daniel Shiffman sends Simon his book and the words he writes there are the most beautiful words anyone has ever told him. Then, on the last day of the awesome year 2017, Simon’s other hero, the glamorous knight of AI Siraj Raval materialises in our living room, directly from YouTube! Happy New Year full of miracles and discoveries everyone!

DSC_3314

Daniel Shiffman’s book “The Nature of Code” that Simon had already largely read online and now also reads before bed. It also comforted him recently when he was in pain, he cuddled up of the sofa with this big friendly tome on his lap.

dsc_33401897498871.jpg

Daniel Shiffman signed the book for Simon:

dsc_33441647117253.jpg

dsc_33421879896746.jpg

Siraj Raval stepped out of the YouTube screen straight into our Antwerp apartment on December 31. Simon has been following Siraj’s channel for months, learning about the types of neural networks and the math behind machine learning. It is thanks to Siraj’s explanations that Simon has been able to build his first neural nets :

DSC_3370

DSC_3364

Schermafbeelding 2018-01-05 om 02.07.56

Advertisements

The Neural Nets are here!

Simon has started building neural networks in Python! For the moment, he has succeeded in making two working neural nets (a Perceptron and a Feed Forward neural net). He used the sigmoid activation function for both. The code partially derived from Siraj Raval’s “The Math of Intelligence” tutorials.

ML Perceptron 10 Dec 2017

The FF was tougher to build:

Simon’s nets run locally (on our home pc), but he will need more computational power for the more complex future projects, so he signed up to this wonderful online resource called FloydHub! FloydHub is sort of a heroku for deep learning, a Platform-as-a-Service for training and deploying deep learning models in the cloud. It uses Amazon, which Simon could, too, but it would have been a lot more expensive and tedious work to set up.

Simon’s next step will be another supervised learning project, a Recurrent Neural Net that will generate text. He has already started building it and fed it one book to read! In this video he explains how character-based text generators work:

Shortest path finder in Processing

Simon created a wonderful project in Processing – a path finder that looks for the shortest path to reach the green cell, avoiding the obstacles. Every time the path finder fails, it tries again. Simon also built a counter for the number of tries. The next step is turning the grid into a game environment and training the path finder, Simon says, i.e. applying reinforcement learning. Simon thinks he should use the Q function in this stochastic environment, but is still very timid about its implementation. In the third video below, he explains how this project could help him take his first cautious steps in the direction of machine learning.

 

 

DAE neural net and Keras

Simon told me today he was ready to start building his own DAE (Denoising Auto Encoder) neural network. He said he would be using a documentation page about a machine learning library called Keras at blog.keras.io/building-autoencoders-in-keras.html. He found this documentation page completely on his own, by searching the web and digging into Python fora. I just watch him google something like “How can I install Keras 1.0?” and find GitHub discussions on the subject that guide him along. Or I see him type “How to install Python on Windows?” and follow the instructions at How-to-Geek. Eventually, he came up with a list of steps that he needed to complete in order to be able to install Keras (installing Python 3 (looking up why it should be 3 and not 2), installing PIP, installing Tensor Flow, etc). It didn’t work on a mac laptop, so he tried everything on a pc and it worked! Two steps required that he used terminal. It was amazing to see him plan ahead, search and implement (notoriously difficult) steps completely independently.

He has started working on the DAE tonight. Working on a node package that makes `manifest.json` files (for Chrome extensions) at the same time, so not sure he’ll finish soon. “Mom, I’ve got so many things to do! There are so many thoughts in my head!”

DSC_2911

Simon working on a neural networks paper

Simon was working on a neural networks paper in Jupyter Notebook on Friday evening, but didn’t finish it because the Coding Train live stream started. He says he can no longer continue without having to do too much copy-pasting from this version into a new one, as his in-your-browser time expired, so I’m posting some screen shots of the unfinished paper below. This is the way Simon teaches himself: he follows lectures and tutorials online and then goes ahead to writing his own “textbook”or recording his own “lecture”. Much of the knowledge he acquires on neural networks these days comes from Siraj Raval’s YouTube series “The Math of Intelligence”.

 

Neural Networks Paper Jupyter 2017-11-20 1

Neural Networks Paper Jupyter 2017-11-20 2

Neural Networks Paper Jupyter 2017-11-20 3

Neural Networks Paper Jupyter 2017-11-20 4

Simon building a Perceptron in Processing

Simon has already built a Perceptron before, several months ago, while following along with Daniel Sgiffman’s Coding Train channel. This time around, he is writing his own code ad doing all the matrix calculations himself. He hasn’t finished programming this network yet, but it’s a good start:

 

DSC_2874

Doing Matrices in Khan Academy’s Precalculus course:

Schermafbeelding 2017-11-16 om 12.34.36

Simon’s bedtime lectures on neural networks

 

 

There’s a part 3 coming!

DSC_2862

DSC_2863

“Mom, my ClickCharts trial period expired, so I found this Virtual Paradigm Enterprise!” (Simon independently searches for free options to make beautiful diagrams online).

Here a diagram of an LSTM neural network:

LSTM Cell in Virtual Paradigm Enterprise 19 Nov 2017 2

And an RNN:

RNN Cell in Virtual Paradigm Enterprise 19 Nov 2017

Just another day in graphs

Simon loves looking at things geometrically. Even when solving word problems, he tends to see them as a graph. And naturally, since he started doing more math related to machine learning, graphs have occupied an even larger portion of his brain! Below are his notes in Microsoft Paint today (from memory):

Slope of Line:

Slope of Line 15 November 2017

Steepness of Curve:

Steepness of Curve 15 November 2017

An awesome calculator Simon discovered online at desmos.com/calculator that allows you to make mobile and static graphs:

Desmos.com Polynomial 15 Nov 2017

Desmos.com Polynomial 15 Nov 2017 1

Yesterday’s notes on the chi function (something he learned through 3Blue1Brown‘s videos on Taylor polynomials):

DSC_2858

Simon following The Math of Intelligence course by Siraj Raval:

DSC_2843

DSC_2840