@@ -230,7 +230,7 @@ def initialize(self, Tmin, Tmax, Pmin, Pmax, maximum_grain_size=0.0, minimum_gra
230230 self .n_j = 0
231231
232232 # Calculate ground-state energies
233- self .E0 = np .zeros ((self .n_isom + self .n_reac + self .n_prod ), np . float64 )
233+ self .E0 = np .zeros ((self .n_isom + self .n_reac + self .n_prod ), float )
234234 for i in range (self .n_isom ):
235235 self .E0 [i ] = self .isomers [i ].E0
236236 for n in range (self .n_reac ):
@@ -261,7 +261,7 @@ def calculate_rate_coefficients(self, Tlist, Plist, method, error_check=True, ne
261261 logging .debug ('' )
262262
263263 logging .info ('Calculating phenomenological rate coefficients for {0}...' .format (rxn ))
264- K = np .zeros ((len (Tlist ), len (Plist ), n_isom + n_reac + n_prod , n_isom + n_reac + n_prod ), np . float64 )
264+ K = np .zeros ((len (Tlist ), len (Plist ), n_isom + n_reac + n_prod , n_isom + n_reac + n_prod ), float )
265265
266266 for t , T in enumerate (Tlist ):
267267 for p , P in enumerate (Plist ):
@@ -381,10 +381,10 @@ def set_conditions(self, T, P, ymB=None):
381381 # Choose the angular momenta to use to compute k(T,P) values at this temperature
382382 # (This only applies if the J-rotor is adiabatic
383383 if not self .active_j_rotor :
384- j_list = self .j_list = np .arange (0 , 20 , 1 , np . int )
384+ j_list = self .j_list = np .arange (0 , 20 , 1 , int )
385385 n_j = self .n_j = len (j_list )
386386 else :
387- j_list = self .j_list = np .array ([0 ], np . int )
387+ j_list = self .j_list = np .array ([0 ], int )
388388 n_j = self .n_j = 1
389389
390390 # Map the densities of states onto this set of energies
@@ -476,9 +476,9 @@ def _get_energy_grains(self, Emin, Emax, grain_size=0.0, grain_count=0):
476476
477477 # Generate the array of energies
478478 if use_grain_size :
479- e_list = np .arange (Emin , Emax + grain_size , grain_size , dtype = np . float64 )
479+ e_list = np .arange (Emin , Emax + grain_size , grain_size , dtype = float )
480480 else :
481- e_list = np .linspace (Emin , Emax , grain_count , dtype = np . float64 )
481+ e_list = np .linspace (Emin , Emax , grain_count , dtype = float )
482482
483483 return e_list
484484
@@ -559,7 +559,7 @@ def calculate_densities_of_states(self):
559559 # Shift the energy grains so that the minimum grain is zero
560560 e_list -= e_list [0 ]
561561
562- dens_states = np .zeros ((n_isom + n_reac + n_prod , n_grains ), np . float64 )
562+ dens_states = np .zeros ((n_isom + n_reac + n_prod , n_grains ), float )
563563
564564 # Densities of states for isomers
565565 for i in range (n_isom ):
@@ -652,9 +652,9 @@ def calculate_microcanonical_rates(self):
652652 n_prod = len (self .products )
653653 n_j = 1 if self .active_j_rotor else len (j_list )
654654
655- self .Kij = np .zeros ([n_isom , n_isom , n_grains , n_j ], np . float64 )
656- self .Gnj = np .zeros ([n_reac + n_prod , n_isom , n_grains , n_j ], np . float64 )
657- self .Fim = np .zeros ([n_isom , n_reac , n_grains , n_j ], np . float64 )
655+ self .Kij = np .zeros ([n_isom , n_isom , n_grains , n_j ], float )
656+ self .Gnj = np .zeros ([n_reac + n_prod , n_isom , n_grains , n_j ], float )
657+ self .Fim = np .zeros ([n_isom , n_reac , n_grains , n_j ], float )
658658
659659 isomers = [isomer .species [0 ] for isomer in self .isomers ]
660660 reactants = [reactant .species for reactant in self .reactants ]
@@ -867,7 +867,7 @@ def calculate_equilibrium_ratios(self):
867867 n_isom = len (self .isomers )
868868 n_reac = len (self .reactants )
869869 n_prod = len (self .products )
870- eq_ratios = np .zeros (n_isom + n_reac + n_prod , np . float64 )
870+ eq_ratios = np .zeros (n_isom + n_reac + n_prod , float )
871871 conc = (1e5 / constants .R / temperature ) # [=] mol/m^3
872872 for i in range (n_isom ):
873873 G = self .isomers [i ].get_free_energy (temperature )
@@ -894,8 +894,8 @@ def calculate_collision_model(self):
894894 n_j = 1 if self .j_list is None else len (self .j_list )
895895
896896 try :
897- coll_freq = np .zeros (n_isom , np . float64 )
898- m_coll = np .zeros ((n_isom , n_grains , n_j , n_grains , n_j ), np . float64 )
897+ coll_freq = np .zeros (n_isom , float )
898+ m_coll = np .zeros ((n_isom , n_grains , n_j , n_grains , n_j ), float )
899899 except MemoryError :
900900 logging .warning ('Collision matrix too large to manage' )
901901 new_n_grains = int (n_grains / 2.0 )
0 commit comments