Skip to content

Commit 72d1e63

Browse files
committed
Merge branch 'develop' of llrgit.in2p3.fr:smilei/smilei into develop
2 parents 749c663 + d319b65 commit 72d1e63

File tree

4 files changed

+45
-27
lines changed

4 files changed

+45
-27
lines changed

src/Python/pyinit.py

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,12 +72,30 @@ def _fillObjectAndAddToList(self, cls, obj, **kwargs):
7272
# add all kwargs as internal class variables
7373
if kwargs is not None:
7474
deprecated = {
75-
"chipa_radiation_threshold":"minimum_chi_continuous",
76-
"chipa_disc_min_threshold":"minimum_chi_discontinuous",
75+
"output_format":"See documentation for radiation reaction",
76+
"h_chipa_min":"See documentation for radiation reaction",
77+
"h_chipa_max":"See documentation for radiation reaction",
78+
"h_dim":"See documentation for radiation reaction",
79+
"h_computation_method":"See documentation for radiation reaction",
80+
"integfochi_chipa_min":"See documentation for radiation reaction",
81+
"integfochi_chipa_max":"See documentation for radiation reaction",
82+
"integfochi_dim":"See documentation for radiation reaction",
83+
"xip_chipa_min":"See documentation for radiation reaction",
84+
"xip_chipa_max":"See documentation for radiation reaction",
85+
"xip_power":"See documentation for radiation reaction or Breit-Wheeler",
86+
"xip_threshold":"See documentation for radiation reaction or Breit-Wheeler",
87+
"xip_chipa_dim":"See documentation for radiation reaction or Breit-Wheeler",
88+
"xip_chiph_dim":"See documentation for radiation reaction or Breit-Wheeler",
89+
"compute_table":"See documentation for Breit-Wheeler",
90+
"T_chiph_min":"See documentation for Breit-Wheeler",
91+
"T_chiph_max":"See documentation for Breit-Wheeler",
92+
"T_dim":"See documentation for Breit-Wheeler",
93+
"xip_chiph_min":"See documentation for Breit-Wheeler",
94+
"xip_chiph_max":"See documentation for Breit-Wheeler",
7795
}
7896
for key, value in kwargs.items():
7997
if key in deprecated:
80-
raise Exception("Deprecated `"+key+"` parameter should be replaced by `"+deprecated[key]+"`")
98+
raise Exception("Deprecated `"+key+"` parameter. "+deprecated[key])
8199
if key=="_list":
82100
print("Python warning: in "+cls.__name__+": cannot have argument named '_list'. Discarding.")
83101
elif not hasattr(cls, key):

validation/analyses/validate_tst1d_18_radiation_spectrum_chi0.1.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -113,14 +113,14 @@ def g(chi):
113113
Prad_MC = np.sum(integrand)
114114

115115
# Compare
116-
print "chi0 = ", chi0
117-
print "g(chi0) = ", g(chi0)
118-
print "Prad (theory) = ", Prad_tot
119-
print "Prad (noRR) = ", Prad_noRR
120-
print "Prad (LL) = ", Prad_LL
121-
print "Prad (cLL) = ", Prad_cLL
122-
print "Prad (FP) = ", Prad_FP
123-
print "Prad (MC) = ", Prad_MC
116+
print( "chi0 = ", chi0)
117+
print( "g(chi0) = ", g(chi0))
118+
print( "Prad (theory) = ", Prad_tot)
119+
print( "Prad (noRR) = ", Prad_noRR)
120+
print( "Prad (LL) = ", Prad_LL)
121+
print( "Prad (cLL) = ", Prad_cLL)
122+
print( "Prad (FP) = ", Prad_FP)
123+
print( "Prad (MC) = ", Prad_MC)
124124

125125
Validate("Prad (noRR)",Prad_noRR, 1.e-6*Prad_noRR)
126126
Validate("Prad (LL)", Prad_LL, 1.e-6*Prad_LL )

validation/analyses/validate_tst2d_10_multiphoton_Breit_Wheeler.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -45,14 +45,14 @@
4545
ntot_positron = np.array(S.Scalar("Ntot_positron").get()["data"])
4646
ntot_photon = np.array(S.Scalar("Ntot_photon").get()["data"])
4747

48-
print ' Final electron energy / total energy: ',ukin_electron[-1] / utot[0]
49-
print ' Final positron energy / total energy: ',ukin_positron[-1] / utot[0]
50-
print ' Final photon energy / total energy: ',ukin_photon[-1] / utot[0]
51-
print ' Maximal relative error total energy: ', max(abs(utot[:] - utot[0]))/utot[0]
52-
53-
print ' Final number of electrons:',ntot_electron[-1]
54-
print ' Final number of positrons: ',ntot_positron[-1]
55-
print ' Final number of photons: ',ntot_photon[-1]
48+
print( ' Final electron energy / total energy: ',ukin_electron[-1] / utot[0] )
49+
print( ' Final positron energy / total energy: ',ukin_positron[-1] / utot[0] )
50+
print( ' Final photon energy / total energy: ',ukin_photon[-1] / utot[0] )
51+
print( ' Maximal relative error total energy: ', max(abs(utot[:] - utot[0]))/utot[0] )
52+
53+
print( ' Final number of electrons:',ntot_electron[-1] )
54+
print( ' Final number of positrons: ',ntot_positron[-1] )
55+
print( ' Final number of photons: ',ntot_photon[-1] )
5656

5757
Validate("Electron kinetic energy evolution: ", ukin_electron/utot[0], 1e-2 )
5858
Validate("Positron kinetic energy evolution: ", ukin_positron/utot[0], 2e-2 )

validation/analyses/validate_tst2d_v_10_multiphoton_Breit_Wheeler.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -45,14 +45,14 @@
4545
ntot_positron = np.array(S.Scalar("Ntot_positron").get()["data"])
4646
ntot_photon = np.array(S.Scalar("Ntot_photon").get()["data"])
4747

48-
print ' Final electron energy / total energy: ',ukin_electron[-1] / utot[0]
49-
print ' Final positron energy / total energy: ',ukin_positron[-1] / utot[0]
50-
print ' Final photon energy / total energy: ',ukin_photon[-1] / utot[0]
51-
print ' Maximal relative error total energy: ', max(abs(utot[:] - utot[0]))/utot[0]
52-
53-
print ' Final number of electrons:',ntot_electron[-1]
54-
print ' Final number of positrons: ',ntot_positron[-1]
55-
print ' Final number of photons: ',ntot_photon[-1]
48+
print( ' Final electron energy / total energy: ',ukin_electron[-1] / utot[0] )
49+
print( ' Final positron energy / total energy: ',ukin_positron[-1] / utot[0] )
50+
print( ' Final photon energy / total energy: ',ukin_photon[-1] / utot[0] )
51+
print( ' Maximal relative error total energy: ', max(abs(utot[:] - utot[0]))/utot[0] )
52+
53+
print( ' Final number of electrons:',ntot_electron[-1] )
54+
print( ' Final number of positrons: ',ntot_positron[-1] )
55+
print( ' Final number of photons: ',ntot_photon[-1] )
5656

5757
Validate("Electron kinetic energy evolution: ", ukin_electron/utot[0], 1e-2 )
5858
Validate("Positron kinetic energy evolution: ", ukin_positron/utot[0], 2e-2 )

0 commit comments

Comments
 (0)