WarpX
Loading...
Searching...
No Matches
MultiDiagnostics Class Reference

This class contains a vector of all diagnostics in the simulation. More...

#include <MultiDiagnostics.H>

Public Member Functions

 MultiDiagnostics ()
 
void ReadParameters ()
 Read Input parameters. Called in constructor.
 
void InitData (const MultiParticleContainer &mpc)
 Loop over diags in alldiags and call their InitDiags.
 
bool DoComputeAndPack (int step, bool force_flush=false)
 
void FilterComputePackFlush (int step, bool force_flush=false, bool BackTransform=false)
 Called at each iteration. Compute diags and flush.
 
void FilterComputePackFlushLastTimestep (int step)
 Called only at the last iteration. Loop over each diag and if m_dump_last_timestep is true, compute diags and flush with force_flush=true.
 
void InitializeFieldFunctors (int lev)
 Loop over diags in all diags and call their InitializeFieldFunctors. Called when a new partitioning is generated at level, lev.
 
void NewIteration ()
 
DiagnosticsGetDiag (int idiag)
 
int GetTotalDiags () const
 
DiagTypes diagstypes (int idiag)
 

Private Attributes

amrex::Vector< std::unique_ptr< Diagnostics > > alldiags
 
int ndiags = 0
 
std::vector< std::string > diags_names
 
std::vector< DiagTypesdiags_types
 

Detailed Description

This class contains a vector of all diagnostics in the simulation.

Constructor & Destructor Documentation

◆ MultiDiagnostics()

MultiDiagnostics::MultiDiagnostics ( )

Resize alldiags and initialize each element to a pointer to a diagnostics. Calls the corresponding diagnostics constructor.

Member Function Documentation

◆ diagstypes()

DiagTypes MultiDiagnostics::diagstypes ( int idiag)
inline

◆ DoComputeAndPack()

bool MultiDiagnostics::DoComputeAndPack ( int step,
bool force_flush = false )

Check if any diagnostics will do compute and pack.

◆ FilterComputePackFlush()

void MultiDiagnostics::FilterComputePackFlush ( int step,
bool force_flush = false,
bool BackTransform = false )

Called at each iteration. Compute diags and flush.

◆ FilterComputePackFlushLastTimestep()

void MultiDiagnostics::FilterComputePackFlushLastTimestep ( int step)

Called only at the last iteration. Loop over each diag and if m_dump_last_timestep is true, compute diags and flush with force_flush=true.

◆ GetDiag()

Diagnostics & MultiDiagnostics::GetDiag ( int idiag)
inline

◆ GetTotalDiags()

int MultiDiagnostics::GetTotalDiags ( ) const
inlinenodiscard

◆ InitData()

void MultiDiagnostics::InitData ( const MultiParticleContainer & mpc)

Loop over diags in alldiags and call their InitDiags.

◆ InitializeFieldFunctors()

void MultiDiagnostics::InitializeFieldFunctors ( int lev)

Loop over diags in all diags and call their InitializeFieldFunctors. Called when a new partitioning is generated at level, lev.

Parameters
[in]levlevel at this the field functors are initialized.

◆ NewIteration()

void MultiDiagnostics::NewIteration ( )

Start a new iteration, i.e., dump has not been done yet.

◆ ReadParameters()

void MultiDiagnostics::ReadParameters ( )

Read Input parameters. Called in constructor.

Member Data Documentation

◆ alldiags

amrex::Vector<std::unique_ptr<Diagnostics> > MultiDiagnostics::alldiags
private

Vector of pointers to all diagnostics

◆ diags_names

std::vector<std::string> MultiDiagnostics::diags_names
private

◆ diags_types

std::vector<DiagTypes> MultiDiagnostics::diags_types
private

Type of each diagnostics

◆ ndiags

int MultiDiagnostics::ndiags = 0
private

number of different diagnostics


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