Theano/Theano — pull request #1539 by jlowin (2013-09-27 17:56:36+00:00)
Title: Add case where 'axis' is a numpy scalar array

If the 'axis' variable is a numpy scalar array (like numpy.array(1)), these conditional branches will fail as it tries to build a set over the non-iterable array. I've added another branch to handle this case.