First TensorFlow Book is Published!

Man, it has been a while since I posted anything!

I’ve emerged from my writer’s cave (along with my co-authors), and have emerged with TensorFlow for Machine Intelligence! In my extremely biased opinion, it’s one of the best resources out there for people trying to get started with TensorFlow. I had a heavy hand in helping design the content of the book, and I wanted to make sure that learning the software was as digestible as possible. I’m not a huge fan of marketing buzz-speak, but one of our reviewers, Guillaume Binet, says

“Finally a TensorFlow book for humans.”

TensorFlow for Machine Intelligence
The book’s snazzy cover!

Mission Accomplished Sort Of!

I Have no idea how it’s going to sell, but hopefully a decent amount of people find the book helpful. Right now, a huge amount of the reward from this process has been getting even more deeply acquainted with the TensorFlow library. Plus, I can literally say “I wrote the book on it”.

I’ve been working on this with the fine folks at Bleeding Edge Press for several months, and while for a book the timeframe has been pretty short, this release feels like a long time coming.

Special thanks to my awesome co-authors Danijar Hafner, Erik Erwitt, and Ariel Scarpinelli. We had a few tight deadlines, but at the end of the day we’ve got an awesome book!

Read More

TensorFlow on Raspberry Pi: Just in Time for Pi Day!

This work was truly a team effort, so please check out the credits of the repo and give everyone there a warm e-hug.

TensorFlow gets smaller as it is getting bigger

Earlier today, I released instructions for compiling TensorFlow on the Raspberry Pi 3, as well as a pre-built Python wheel that can be used to install it directly. I’m hoping that this will enable some really cool projects involving both portable GPIO device-based learning and experimentation with TensorFlow’s distributed runtime. This has been an effort that has gone on since TensorFlow was open-sourced, and I’m really happy to be part of the group of people that made it happen.

What’s in the Repo

There are two main attractions to the repository: a pre-built Python wheel that can be used to easily install TensorFlow on a Raspberry Pi 3, and a step-by-step guide to building TensorFlow yourself.

Why Bother?

Several people have asked similar questions along the lines of: “Why would you want to run TensorFlow on a Raspberry Pi? Its compute power is miniscule.”

The first, quick answer: you probably don’t want to train your sophisticated models on a Raspberry Pi. Instead, train the model on a computer with more processing power (both CPU and GPU), and then move that pre-trained model onto the Pi for real-time use.

The second, more verbose answer:

With so much focus on the insane amount of computing power some companies are using to create breakthroughs in machine learning, such as Google’s AlphaGo recently beating Go champion Lee Sedol, it’s easy to get caught in the mindset that the only worthwhile machine learning problems require hundreds of GPUs. In truth, there are many applications that are on the opposite end of the spectrum- embedded devices with limited memory and processing power can also take advantage of machine learning. Unfortunately, you can’t keep throwing more hardware in a device smaller than your hand. We don’t want to require our smart health-monitors to be hooked up to the internet in order to detect anomalies- they should be able to use some sort of model built into the device. The hope is that by having a widely cross-compatible and powerful framework, the barrier to making ML-capable devices will be lowered and installing pre-trained models becomes less of a headache on devices with limited hardware.

Plus, having access to GPIO sensors and other devices could enable some really cool prototypes for machine learning that incorporate realtime data from their surroundings. Good stuff all around!

So check it out, let me know what works (and what doesn’t work), and let’s keep making TensorFlow a kick-ass framework with a kick-community.

Read More

TensorFlow Serving: TensorFlow in Production

More good news!

Google announced today that they’re releasing TensorFlow Serving a way to maintain machine learning models that are defined and trained in TensorFlow.

In a typical production setting, you want a way to replace in new models, or possibly train a model online. However, you need to be able to make this process seamless, or else risk losing service for a period of time. TensorFlow Serving offers a framework that manages the behind the scenes work of this process, so that the user can spend more time trying out new models. It’s in its infancy right now, but I’m excited to try it out soon.

Read More

Aside: Back from Israel and A New Small Program

Happy New Year!

Alright! Back from Taglit/Birthright a little more tan, a little more mensch-y. Here’s what I’ve been up to in the digital (though occasionally also spiritual) world:

  • Helped out with some documentation on the TensorFlow repo. Really enjoying the little bits of collaboration with the Google folks I’ve been able to have with that. I’d say that one thing that could be improved is a little bit more information about which components Google is actively working toward releasing. After taking notes on their white paper, there are several important features that exist in Google’s internal implementation that have yet to be open-sourced. I think making an explicit list of these features will help guide the open source community to work on new problems (and maybe just maybe stop asking about the same things over and over again. It’s coming guys! Google wants TensorFlow to succeed)
  • A pull request I made in October for the Node.js linear algebra package finally got merged! The maintainer hadn’t touched the project for over a year, but now it seems like there’s been more life. Sadly, my ambitions of creating a simple JavaScript feed-forward neural network executor have been set off course, as learning and using TensorFlow seems to be a better use of time (along with several other projects). Hopefully the new feature is useful to someone!
  • Continued to make some updates on the previously mentioned TensorFlow white paper notes

Additionally, I’ve got a little Python project that I hope will improve people’s lives! For the moment, it’s called:


Check out the repo here. Basically, it should make intra- and inter-Markdown document anchor links more sensible to use in GitHub. Headers in Markdown files are automatically given anchor tags on GitHub, but they can get a little verbose and/or difficult to utilize. One might end up uploading a file, copying the anchor URL (using the chain icon next to the header), pasting that URL back into the document, and uploading a second time. A waste of time AND it clutters up the commit log. Here’s the basics of what AnchorHub does:

What you write:
# This is a header that I would like to make an id for {#head}
[This link points to that header!](#head)

What AnchorHub outputs:
# This is a header that I would like to make an id for
[This link points to that header!](#this-is-a-header-that-i-would-like-to-make-an-id-for)

It works automatically within an entire directory tree, so you can link across documents the same way you might use id tags in HTML. There’s still plenty of work to be done, but it is actually usable right now! Command-line arguments coming up next after fixing a last second bug. Then onto pip-packaging!

Read More

TensorFlow White Pages Notes – On GitHub

Hey all!

Huge content in a short post. I just released my TensorFlow white paper notes on GitHub. It’s been a much larger project than I originally thought, but I hope that it will be useful to people. The notes go from the very beginning of the paper all the way through conclusions, highlighting the important information from each section.

Here are the top features of the notes:

  • Notes broken down and organized section by section, as well as subsection by subsection
  • Relevant links to documentation, resources, and references throughout
  • SVG versions of figures/graphs from the paper

If you haven’t checked out the TensorFlow white paper yet, I highly recommend it. There’s no replacement for reading the original, but I hope these notes are a worthy supplement alongside the actual paper.

Next up: Using TensorFlow on transformed Santa Monica Parking data

Read More