theano code for exercising