Peano
Loading...
Searching...
No Matches
postprocessing.PerformanceData.PerformanceData Class Reference
Inheritance diagram for postprocessing.PerformanceData.PerformanceData:
Collaboration diagram for postprocessing.PerformanceData.PerformanceData:

Public Member Functions

 __init__ (self, file_name, solver_name="", verbose=False)
 :: Attributes
 __str__ (self, *args, **kwargs)
 parse (self, verbose)
 get_time_per_time_step (self)
 Returns a whole array of times per time step, so you can plot the evoluation of the cost per step over time.
 get_average_time_per_time_step (self)
 Returns a whole array of times per time step, so you can plot the evoluation of the cost per step over time.
 get_updates (self)
 get_time_step_real_time_stamps (self)
 Returns a series of real time stamps (in seconds) snapshotted per time step.
 get_time_step_simulated_time_stamps (self)
 Returns a sequence of time stamps that are the simulated time stamps (where has the simulation been at a certain point) per step.
 get_time_step_time_step_size (self)
 uses_local_timestepping (self)
 timesteps (self)
 Should maybe eliminate the time steps that are not really steps.
 time_per_time_step (self)
 Time of last time step normalised (multiplied) with h^d.
 remove_first_n_entries (self, count)
 Remove the first count entries from the dataset.

Data Fields

int total_construction_time = 0
int total_time_stepping_time = 0
int total_plotting_time = 0
int total_construction_steps = 0
int total_time_stepping_steps = 0
int total_plotting_steps = 0
list plotting_time_stamp = []
bool valid = False

Protected Attributes

 _file_name = file_name
 _solver_name = solver_name
int _threads = 1
int _ranks = 1
int _cores_per_node = 1
list _time_step_time_stamp = []
list _simulated_time_stamp_max = []
list _simulated_time_stamp_min = []
list _time_step_size_max = []
list _time_step_size_min = []
list _updates = []
int _number_of_time_steps = 0
bool _parse_machine_time_format = True
int _d = 2

Private Member Functions

 __convert_machine_readable_timestamp_to_seconds (self, data)
 Hand in a string in nanoseconds and return double as s.
 __convert_human_readable_timestamp_to_seconds (self, data)
 Hand in a string in the format hh:mm:ss.
 __extract_time_stamp_from_run_call (self, line)

Detailed Description

Definition at line 11 of file PerformanceData.py.

Constructor & Destructor Documentation

◆ __init__()

postprocessing.PerformanceData.PerformanceData.__init__ ( self,
file_name,
solver_name = "",
verbose = False )

:: Attributes

self._number_of_time_steps: Int Includes the empty time steps (warm-up phase) if you have adaptive time stepping.

:: Arguments

file_name: String This is a mandatory field, as it tells us which file to parse.

solver_name: String In theory, you could live without this one if you have only one solver. However, ExaHyPE2 supports multiple solvers within one grid and therefore needs a dedicated solver name to know where to look in the file. Leave it empty if there's only one solver.

Definition at line 12 of file PerformanceData.py.

Member Function Documentation

◆ __convert_human_readable_timestamp_to_seconds()

postprocessing.PerformanceData.PerformanceData.__convert_human_readable_timestamp_to_seconds ( self,
data )
private

Hand in a string in the format hh:mm:ss.

Definition at line 84 of file PerformanceData.py.

Referenced by __extract_time_stamp_from_run_call().

Here is the caller graph for this function:

◆ __convert_machine_readable_timestamp_to_seconds()

postprocessing.PerformanceData.PerformanceData.__convert_machine_readable_timestamp_to_seconds ( self,
data )
private

Hand in a string in nanoseconds and return double as s.

Definition at line 74 of file PerformanceData.py.

Referenced by __extract_time_stamp_from_run_call().

Here is the caller graph for this function:

◆ __extract_time_stamp_from_run_call()

postprocessing.PerformanceData.PerformanceData.__extract_time_stamp_from_run_call ( self,
line )
private

◆ __str__()

◆ get_average_time_per_time_step()

postprocessing.PerformanceData.PerformanceData.get_average_time_per_time_step ( self)

Returns a whole array of times per time step, so you can plot the evoluation of the cost per step over time.

Definition at line 266 of file PerformanceData.py.

References get_time_per_time_step().

Here is the call graph for this function:

◆ get_time_per_time_step()

postprocessing.PerformanceData.PerformanceData.get_time_per_time_step ( self)

Returns a whole array of times per time step, so you can plot the evoluation of the cost per step over time.

Definition at line 253 of file PerformanceData.py.

References _time_step_time_stamp.

Referenced by get_average_time_per_time_step().

Here is the caller graph for this function:

◆ get_time_step_real_time_stamps()

postprocessing.PerformanceData.PerformanceData.get_time_step_real_time_stamps ( self)

Returns a series of real time stamps (in seconds) snapshotted per time step.

This is not a mere copy, as the last entry in the local set is the end of the simulation. So we remove this one. At the same time, the very first entry is the start of the simulation or first time step where nothing happens yet (if we have to analyse the eigenvalue first).

Definition at line 287 of file PerformanceData.py.

References _time_step_time_stamp.

◆ get_time_step_simulated_time_stamps()

postprocessing.PerformanceData.PerformanceData.get_time_step_simulated_time_stamps ( self)

Returns a sequence of time stamps that are the simulated time stamps (where has the simulation been at a certain point) per step.

This is not a mere copy, as the last entry in the local set is the end of the simulation

Definition at line 306 of file PerformanceData.py.

References _simulated_time_stamp_max, _simulated_time_stamp_min, and uses_local_timestepping().

Here is the call graph for this function:

◆ get_time_step_time_step_size()

postprocessing.PerformanceData.PerformanceData.get_time_step_time_step_size ( self)

Definition at line 326 of file PerformanceData.py.

References _time_step_size_max, _time_step_size_min, and uses_local_timestepping().

Here is the call graph for this function:

◆ get_updates()

postprocessing.PerformanceData.PerformanceData.get_updates ( self)

Definition at line 283 of file PerformanceData.py.

References _updates.

◆ parse()

◆ remove_first_n_entries()

postprocessing.PerformanceData.PerformanceData.remove_first_n_entries ( self,
count )

Remove the first count entries from the dataset.

Usually, count is one and anticipates that the solver requires one warm up sweep to determine h and the eigenvalue, e.g.

Definition at line 366 of file PerformanceData.py.

References _simulated_time_stamp_max, _simulated_time_stamp_min, _time_step_size_max, _time_step_size_min, and _time_step_time_stamp.

◆ time_per_time_step()

postprocessing.PerformanceData.PerformanceData.time_per_time_step ( self)

Time of last time step normalised (multiplied) with h^d.

Definition at line 356 of file PerformanceData.py.

References total_time_stepping_steps, and total_time_stepping_time.

◆ timesteps()

postprocessing.PerformanceData.PerformanceData.timesteps ( self)

Should maybe eliminate the time steps that are not really steps.

Definition at line 345 of file PerformanceData.py.

References _time_step_size_max, and _time_step_size_min.

◆ uses_local_timestepping()

postprocessing.PerformanceData.PerformanceData.uses_local_timestepping ( self)

Definition at line 336 of file PerformanceData.py.

References _time_step_size_max, and _time_step_size_min.

Referenced by get_time_step_simulated_time_stamps(), and get_time_step_time_step_size().

Here is the caller graph for this function:

Field Documentation

◆ _cores_per_node

int postprocessing.PerformanceData.PerformanceData._cores_per_node = 1
protected

Definition at line 37 of file PerformanceData.py.

◆ _d

int postprocessing.PerformanceData.PerformanceData._d = 2
protected

Definition at line 138 of file PerformanceData.py.

◆ _file_name

postprocessing.PerformanceData.PerformanceData._file_name = file_name
protected

Definition at line 32 of file PerformanceData.py.

Referenced by parse().

◆ _number_of_time_steps

postprocessing.PerformanceData.PerformanceData._number_of_time_steps = 0
protected

Definition at line 56 of file PerformanceData.py.

Referenced by __str__().

◆ _parse_machine_time_format

bool postprocessing.PerformanceData.PerformanceData._parse_machine_time_format = True
protected

Definition at line 67 of file PerformanceData.py.

Referenced by __extract_time_stamp_from_run_call().

◆ _ranks

postprocessing.PerformanceData.PerformanceData._ranks = 1
protected

Definition at line 36 of file PerformanceData.py.

Referenced by __str__().

◆ _simulated_time_stamp_max

list postprocessing.PerformanceData.PerformanceData._simulated_time_stamp_max = []
protected

◆ _simulated_time_stamp_min

list postprocessing.PerformanceData.PerformanceData._simulated_time_stamp_min = []
protected

◆ _solver_name

postprocessing.PerformanceData.PerformanceData._solver_name = solver_name
protected

Definition at line 33 of file PerformanceData.py.

◆ _threads

postprocessing.PerformanceData.PerformanceData._threads = 1
protected

Definition at line 35 of file PerformanceData.py.

Referenced by __str__(), and parse().

◆ _time_step_size_max

postprocessing.PerformanceData.PerformanceData._time_step_size_max = []
protected

◆ _time_step_size_min

postprocessing.PerformanceData.PerformanceData._time_step_size_min = []
protected

◆ _time_step_time_stamp

postprocessing.PerformanceData.PerformanceData._time_step_time_stamp = []
protected

◆ _updates

list postprocessing.PerformanceData.PerformanceData._updates = []
protected

Definition at line 54 of file PerformanceData.py.

Referenced by get_updates().

◆ plotting_time_stamp

list postprocessing.PerformanceData.PerformanceData.plotting_time_stamp = []

Definition at line 47 of file PerformanceData.py.

◆ total_construction_steps

postprocessing.PerformanceData.PerformanceData.total_construction_steps = 0

Definition at line 43 of file PerformanceData.py.

Referenced by __str__().

◆ total_construction_time

postprocessing.PerformanceData.PerformanceData.total_construction_time = 0

Definition at line 39 of file PerformanceData.py.

Referenced by __str__().

◆ total_plotting_steps

postprocessing.PerformanceData.PerformanceData.total_plotting_steps = 0

Definition at line 45 of file PerformanceData.py.

Referenced by __str__().

◆ total_plotting_time

postprocessing.PerformanceData.PerformanceData.total_plotting_time = 0

Definition at line 41 of file PerformanceData.py.

Referenced by __str__().

◆ total_time_stepping_steps

postprocessing.PerformanceData.PerformanceData.total_time_stepping_steps = 0

Definition at line 44 of file PerformanceData.py.

Referenced by __str__(), and time_per_time_step().

◆ total_time_stepping_time

postprocessing.PerformanceData.PerformanceData.total_time_stepping_time = 0

Definition at line 40 of file PerformanceData.py.

Referenced by __str__(), and time_per_time_step().

◆ valid

postprocessing.PerformanceData.PerformanceData.valid = False

Definition at line 69 of file PerformanceData.py.

Referenced by __str__(), and parse().


The documentation for this class was generated from the following file: