NumPy or TensorFlow?

The main thing youโ€™d be missing by using Numpy for Machine Learning is the possibility of reusing other peopleโ€™s work (and, thatโ€™s a very big one).

Tensorflow is enjoying insanely fast adoption and is currently the mainstream deep learning platform. This makes for the fact that there are thousands of Github pages implementing recent papers on DeepLearning where you can just copy all the code and start working with state of the art ML models on you own data / projects.

Imagine having to implement something like a Differentiable Neural Computer yourself in Numpyโ€ฆ Would probably take weeks and the resulting model might be full of small bugs causing it to not train at all. But hey, DeepMind published their full code online a few weeks ago, so why would you even bother redoing that yourself? :)

On the other hand, to really understand what a deep learning algorithm is actually doing under the hood (backprop, exploding gradients, โ€ฆ) Numpy can be very useful because it gets rid of all the overhead and shows you the raw computation. This great post on Reinforcement Learning clearly shows this point by distilling a rather complicated concept in a very interpretable way using Numpy.

So to wrap up:

If you are new to deep learning and want to understand the underlying concepts of backpropagation and experiment with the code a bit without requiring you to learn a whole new framework: use Numpy.

Last updated