Peano
Loading...
Searching...
No Matches
OutputFile.OutputFile Class Reference

Represents single output file dumped by Peano. More...

Inheritance diagram for OutputFile.OutputFile:
Collaboration diagram for OutputFile.OutputFile:

Public Member Functions

 __init__ (self, name, verbose=False)
 
 parse (self)
 Parse Peano output file.
 
 ranks (self)
 
 threads_per_rank (self)
 
 runtime (self)
 Read out the total runtime.
 
 trees_per_snapshot (self, rank)
 Return a sequence of integers that holds the number of trees per snapshot.
 
 local_cells_per_snapshot (self, rank)
 Return local cells per snaphot.
 
 virtual_cells_per_snapshot (self, rank)
 Return local cells per snaphot.
 
 total_local_cells_per_snapshot (self, rank)
 Return the total number of cells per snapshot for this rank.
 
 min_local_cells_per_snapshot (self, rank)
 Return the total number of cells per snapshot for this rank.
 
 max_local_cells_per_snapshot (self, rank)
 Return the total number of cells per snapshot for this rank.
 
 min_virtual_cells_per_snapshot (self, rank)
 Return the total number of cells per snapshot for this rank.
 
 max_virtual_cells_per_snapshot (self, rank)
 Return the total number of cells per snapshot for this rank.
 
 is_valid (self)
 

Protected Attributes

 _file_name
 
 _has_parsed
 
 _verbose
 
 _snapshot_lines
 
 _ranks
 
 _threads
 
 _runtime
 

Detailed Description

Represents single output file dumped by Peano.

This class extracts all the load balancing-related information from an output file, i.e. is basically an abstraction of a file parser. It also holds some very basic runtime data.

Parameters
nameFile name

Definition at line 4 of file OutputFile.py.

Constructor & Destructor Documentation

◆ __init__()

OutputFile.OutputFile.__init__ ( self,
name,
verbose = False )

Definition at line 15 of file OutputFile.py.

Member Function Documentation

◆ is_valid()

OutputFile.OutputFile.is_valid ( self)

Definition at line 292 of file OutputFile.py.

◆ local_cells_per_snapshot()

OutputFile.OutputFile.local_cells_per_snapshot ( self,
rank )

Return local cells per snaphot.

This is a sequence of sequences. For each snapshot for this rank, we store one sequence with all the local cells in this snapshot. The standard plot_load_distribution.py script feeds this data into a scatter plot. For many cases, we might however be interested in the maximum value:

raw_data = ouput_file.local_cells_per_snapshot(rank)
max_data = [max(x) for x in raw_data ]

Definition at line 131 of file OutputFile.py.

References exahype2.postprocessing.PerformanceData.PerformanceData._ranks, OutputFile.OutputFile._ranks, OutputFile.OutputFile._snapshot_lines, convert::input::PeanoTextPatchFileReader.parse(), convert::input::MetaFileReader.parse(), convert::input::PatchFileReader.parse(), toolbox::curvi::YAMLInput.parse(), OutputFile.OutputFile.parse(), peano4.toolbox.particles.postprocessing.Dataset.Dataset.parse(), exahype2.kerneldsl.Parser.Parser.parse(), and exahype2.postprocessing.PerformanceData.PerformanceData.parse().

Referenced by OutputFile.OutputFile.max_local_cells_per_snapshot(), OutputFile.OutputFile.min_local_cells_per_snapshot(), and OutputFile.OutputFile.total_local_cells_per_snapshot().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ max_local_cells_per_snapshot()

OutputFile.OutputFile.max_local_cells_per_snapshot ( self,
rank )

Return the total number of cells per snapshot for this rank.

The total number of cells is an interesting quantity, as it allows us to compare the load of different ranks.

Definition at line 232 of file OutputFile.py.

References OutputFile.OutputFile.local_cells_per_snapshot().

Here is the call graph for this function:

◆ max_virtual_cells_per_snapshot()

OutputFile.OutputFile.max_virtual_cells_per_snapshot ( self,
rank )

Return the total number of cells per snapshot for this rank.

The total number of cells is an interesting quantity, as it allows us to compare the load of different ranks.

Definition at line 272 of file OutputFile.py.

References OutputFile.OutputFile.virtual_cells_per_snapshot().

Here is the call graph for this function:

◆ min_local_cells_per_snapshot()

OutputFile.OutputFile.min_local_cells_per_snapshot ( self,
rank )

Return the total number of cells per snapshot for this rank.

The total number of cells is an interesting quantity, as it allows us to compare the load of different ranks.

Definition at line 212 of file OutputFile.py.

References OutputFile.OutputFile.local_cells_per_snapshot().

Here is the call graph for this function:

◆ min_virtual_cells_per_snapshot()

OutputFile.OutputFile.min_virtual_cells_per_snapshot ( self,
rank )

Return the total number of cells per snapshot for this rank.

The total number of cells is an interesting quantity, as it allows us to compare the load of different ranks.

Definition at line 252 of file OutputFile.py.

References OutputFile.OutputFile.virtual_cells_per_snapshot().

Here is the call graph for this function:

◆ parse()

◆ ranks()

◆ runtime()

◆ threads_per_rank()

◆ total_local_cells_per_snapshot()

OutputFile.OutputFile.total_local_cells_per_snapshot ( self,
rank )

Return the total number of cells per snapshot for this rank.

The total number of cells is an interesting quantity, as it allows us to compare the load of different ranks.

Definition at line 192 of file OutputFile.py.

References OutputFile.OutputFile.local_cells_per_snapshot().

Here is the call graph for this function:

◆ trees_per_snapshot()

◆ virtual_cells_per_snapshot()

OutputFile.OutputFile.virtual_cells_per_snapshot ( self,
rank )

Field Documentation

◆ _file_name

◆ _has_parsed

OutputFile.OutputFile._has_parsed
protected

Definition at line 21 of file OutputFile.py.

Referenced by OutputFile.OutputFile.parse().

◆ _ranks

◆ _runtime

OutputFile.OutputFile._runtime
protected

Definition at line 66 of file OutputFile.py.

Referenced by OutputFile.OutputFile.runtime().

◆ _snapshot_lines

◆ _threads

◆ _verbose


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