C++ version of http://deeplearning.net/tutorial/