#NEWLINE# def _get_gradients( self ) : #NEWLINE# #INDENT# gparams = T . grad ( cost = self . loss , wrt = self . model . parameters , consider_constant = self . consider_constant ) #NEWLINE# self . _gradients = OrderedDict ( zip ( self . model . parameters , gparams ) ) #NEWLINE# return self . gradients