#NEWLINE# def __init__( self , h_new_coeff_schedule , s_new_coeff_schedule = None , clip_reflections = False , monitor_kl = False , monitor_energy_functional = False , monitor_s_mag = False , rho = 0.5 , monitor_ranges = False ) : #NEWLINE# #INDENT# self . autonomous = True #NEWLINE# if ( h_new_coeff_schedule is None ) : #NEWLINE# #INDENT# self . autonomous = False #NEWLINE# assert ( s_new_coeff_schedule is None ) #NEWLINE# assert ( rho is None ) #NEWLINE# assert ( clip_reflections is None ) #NEWLINE# assert ( monitor_energy_functional is None ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( s_new_coeff_schedule is None ) : #NEWLINE# #INDENT# s_new_coeff_schedule = [ 1.0 for cur_rho in h_new_coeff_schedule ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( len ( s_new_coeff_schedule ) != len ( h_new_coeff_schedule ) ) : #NEWLINE# #INDENT# raise ValueError ( ( ( 's_new_coeff_schedule has %d elems ' % ( len ( s_new_coeff_schedule ) , ) ) + ( 'but h_new_coeff_schedule has %d elems' % ( len ( h_new_coeff_schedule ) , ) ) ) ) #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# if ( s_new_coeff_schedule is not None ) : #NEWLINE# #INDENT# assert isinstance ( s_new_coeff_schedule , ( list , tuple ) ) #NEWLINE# #UNINDENT# if ( h_new_coeff_schedule is not None ) : #NEWLINE# #INDENT# assert isinstance ( h_new_coeff_schedule , ( list , tuple ) ) #NEWLINE# #UNINDENT# self . s_new_coeff_schedule = s_new_coeff_schedule #NEWLINE# self . clip_reflections = clip_reflections #NEWLINE# self . h_new_coeff_schedule = h_new_coeff_schedule #NEWLINE# self . monitor_kl = monitor_kl #NEWLINE# self . monitor_energy_functional = monitor_energy_functional #NEWLINE# self . monitor_ranges = monitor_ranges #NEWLINE# if self . autonomous : #NEWLINE# #INDENT# self . rho = as_floatX ( rho ) #NEWLINE# #UNINDENT# self . monitor_s_mag = monitor_s_mag #NEWLINE# self . model = None