fix a NotScalarConstantError issue

This fixes the bug that is making the pylearn2 travisbot not work.