Class for doing restart. More...
#include <RestartableDataIO.h>
Public Member Functions | |
RestartableDataIO (MooseApp &app, RestartableDataMap &data) | |
RestartableDataIO (MooseApp &app, std::vector< RestartableDataMap > &data) | |
PerfGraph & | perfGraph () |
Get the PerfGraph. More... | |
const Parallel::Communicator & | comm () const |
processor_id_type | n_processors () const |
processor_id_type | processor_id () const |
Static Public Member Functions | |
static const std::string & | getRestartableExt () |
static const std::string & | restartableDataFile () |
static const std::string & | restartableHeaderFile () |
static std::filesystem::path | restartableDataFolder (const std::filesystem::path &folder_base) |
static std::filesystem::path | restartableDataFile (const std::filesystem::path &folder_base) |
static std::filesystem::path | restartableHeaderFile (const std::filesystem::path &folder_base) |
static InputParameters | validParams () |
Protected Types | |
typedef int | COMPARE_HASH_CODE_TYPE |
The type to used for comparing hash codes (sanity checking) More... | |
Protected Member Functions | |
RestartableDataMap & | currentData (const THREAD_ID tid) |
std::size_t | dataSize () const |
PerfID | registerTimedSection (const std::string §ion_name, const unsigned int level) const |
Call to register a named section for timing. More... | |
PerfID | registerTimedSection (const std::string §ion_name, const unsigned int level, const std::string &live_message, const bool print_dots=true) const |
Call to register a named section for timing. More... | |
std::string | timedSectionName (const std::string §ion_name) const |
Protected Attributes | |
const std::variant< RestartableDataMap *, std::vector< RestartableDataMap > * > | _data |
The data we wish to act on This is a variant so that we can act on threaded and non-threaded data. More... | |
MooseApp & | _pg_moose_app |
The MooseApp that owns the PerfGraph. More... | |
const std::string | _prefix |
A prefix to use for all sections. More... | |
const Parallel::Communicator & | _communicator |
Static Protected Attributes | |
static const unsigned int | CURRENT_BACKUP_FILE_VERSION = 4 |
The current version for the backup file. More... | |
Class for doing restart.
It takes care of writing and reading the restart files.
Definition at line 27 of file RestartableDataIO.h.
|
protected |
The type to used for comparing hash codes (sanity checking)
Definition at line 84 of file RestartableDataIO.h.
RestartableDataIO::RestartableDataIO | ( | MooseApp & | app, |
RestartableDataMap & | data | ||
) |
Definition at line 18 of file RestartableDataIO.C.
RestartableDataIO::RestartableDataIO | ( | MooseApp & | app, |
std::vector< RestartableDataMap > & | data | ||
) |
Definition at line 25 of file RestartableDataIO.C.
|
protected |
tid
This exists so that we can support threaded and non-threaded data in _data
Definition at line 33 of file RestartableDataIO.C.
Referenced by RestartableDataReader::restore(), RestartableDataReader::restoreData(), and RestartableDataWriter::write().
|
protected |
Definition at line 43 of file RestartableDataIO.C.
Referenced by currentData(), RestartableDataReader::readHeader(), RestartableDataReader::restore(), and RestartableDataWriter::write().
|
static |
Definition at line 51 of file RestartableDataIO.C.
Referenced by restartableDataFolder().
|
inherited |
Get the PerfGraph.
Definition at line 78 of file PerfGraphInterface.C.
Referenced by CommonOutputAction::act(), PerfGraphData::finalize(), and PerfGraphOutput::output().
|
protectedinherited |
Call to register a named section for timing.
section_name | The name of the code section to be timed |
level | The importance of the timer - lower is more important (0 will always come out) |
Definition at line 53 of file PerfGraphInterface.C.
|
protectedinherited |
Call to register a named section for timing.
section_name | The name of the code section to be timed |
level | The importance of the timer - lower is more important (0 will always come out) |
live_message | The message to be printed to the screen during execution |
print_dots | Whether or not progress dots should be printed for this section |
Definition at line 64 of file PerfGraphInterface.C.
|
static |
Definition at line 58 of file RestartableDataIO.C.
Referenced by RestartableDataReader::isAvailable(), restartableDataFile(), RestartableDataReader::setInput(), and RestartableDataWriter::write().
|
static |
folder_base
Does not append .rd to the folder base
Definition at line 80 of file RestartableDataIO.C.
|
static |
folder_base
This just appends .rd
Definition at line 72 of file RestartableDataIO.C.
Referenced by MooseApp::metaDataFolderBase(), and MooseApp::restartFolderBase().
|
static |
Definition at line 65 of file RestartableDataIO.C.
Referenced by restartableHeaderFile(), RestartableDataReader::setInput(), and RestartableDataWriter::write().
|
static |
folder_base
Does not append .rd to the folder base
Definition at line 86 of file RestartableDataIO.C.
|
protectedinherited |
section_name
.Optionally adds a prefix if one is defined.
Definition at line 47 of file PerfGraphInterface.C.
Referenced by PerfGraphInterface::registerTimedSection().
|
staticinherited |
Definition at line 16 of file PerfGraphInterface.C.
|
protected |
The data we wish to act on This is a variant so that we can act on threaded and non-threaded data.
Definition at line 79 of file RestartableDataIO.h.
Referenced by currentData(), and dataSize().
|
protectedinherited |
The MooseApp that owns the PerfGraph.
Definition at line 124 of file PerfGraphInterface.h.
Referenced by PerfGraphInterface::perfGraph().
|
protectedinherited |
A prefix to use for all sections.
Definition at line 127 of file PerfGraphInterface.h.
Referenced by PerfGraphInterface::timedSectionName().
|
staticprotected |
The current version for the backup file.
Definition at line 82 of file RestartableDataIO.h.
Referenced by RestartableDataReader::readHeader(), and RestartableDataWriter::write().