aboutsummaryrefslogtreecommitdiff
path: root/Examples/Tests/restart/analysis_restart.py
diff options
context:
space:
mode:
Diffstat (limited to 'Examples/Tests/restart/analysis_restart.py')
-rwxr-xr-xExamples/Tests/restart/analysis_restart.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/Examples/Tests/restart/analysis_restart.py b/Examples/Tests/restart/analysis_restart.py
index 698ef8a7d..0c0f01df5 100755
--- a/Examples/Tests/restart/analysis_restart.py
+++ b/Examples/Tests/restart/analysis_restart.py
@@ -12,6 +12,7 @@ print('tolerance = ', tolerance)
filename = sys.argv[1]
psatd = True if re.search('psatd', filename) else False
+averaged = True if re.search('avg', filename) else False
ds = yt.load( filename )
ad = ds.all_data()
@@ -20,7 +21,11 @@ xe = ad['plasma_e', 'particle_position_x'].to_ndarray()
zb = ad['beam', 'particle_position_z'].to_ndarray()
ze = ad['plasma_e', 'particle_position_z'].to_ndarray()
-filename = 'orig_restart_psatd_plt00010' if (psatd) else 'orig_restart_plt00010'
+filename = 'orig_restart_plt00010'
+if psatd:
+ filename = 'orig_restart_psatd_plt00010'
+if averaged:
+ filename = 'orig_restart_psatd_time_avg_plt00010'
ds = yt.load( filename )
ad = ds.all_data()
xb0 = ad['beam', 'particle_position_x'].to_ndarray()