fixing bug in deep learn toolbox