Why yes, I’m running a deep learning system on a MacBook Air. Why?

deeplearning.png

Yep, that’s Python consuming almost 300% of my CPU – guess what, I guess that means this machine has four processing cores, since I saw it hit over 300% – running the TensorFlow tutorial. For those that don’t know, “deep learning” is a relatively recent type of learning which uses improvements in both processing power and learning algorithms to train learning networks that can have dozens or hundreds of layers – sometimes as many layers as neural networks in the 1980’s and 1990’s had nodes.

For those that don’t know even that, neural networks are graphs of simple nodes that mimic brain structures, and you can train them with data that contains both the question and the answer. With enough internal layers, neural networks can learn almost anything, but they require a lot of training data and a lot of computing power. Well, now we’ve got lots and lots of data, and with more computing power, you’d expect we’d be able to train larger networks – but the first real trick was discovering mathematical tricks that keep the learning signal strong deep, deep within the networks.

The second real trick was wrapping all this amazing code in a clean software architecture that enables anyone to run the software anywhere. TensorFlow is one of the most recent of these frameworks – it’s Google’s attempt to package up the deep learning technology it uses internally so that everyone in the world can use it – and it’s open source, so you can download and install it on most computers and try out the tutorial at home. The CPU-baking example you see running here, however, is not the simpler tutorial, but a test program that runs a full deep neural network. Let’s see how it did:

Screenshot 2016-02-08 21.08.40.png

Well. 99.2% correct, it seems. Not bad for a couple hundred lines of code, half of which is loading the test data – and yeah, that program depends on 200+ files worth of Python that the TensorFlow installation loaded onto my MacBook Air, not to mention all the libraries that the TensorFlow Python installation depends on in turn …

But I still loaded it onto a MacBook Air, and it ran perfectly.

Amazing what you can do with computers these days.

-the Centaur

Leave a Reply

Your email address will not be published. Required fields are marked *