|
Peano
|
Default realisation of exahype2.api.Project.mainfile_generator. More...


Public Member Functions | |
| __init__ (self, Project project) | |
| construct_output (self, peano_project) | |
| Add this generator's output to peano_project (a peano4.api.Project-compatible object, or anything else that add()'s cleanly into peano_project.output). | |
| Public Member Functions inherited from exahype2.api.Project.Project.Generator | |
| __init__ (self, "Project" project) | |
Additional Inherited Members | |
| Data Fields inherited from exahype2.api.Project.Project.Generator | |
| project = project | |
Default realisation of exahype2.api.Project.mainfile_generator.
Mirrors SolverToCPPFiles on the solver side: turns the project configuration into the header/implementation file pair that ends up holding main(), similar in spirit to python/exahype2/ExaHyPEMain.template.h/.cpp. Rather than emitting that file pair itself, it replaces peano_project's generic peano4-level main file generator (peano4.api.runner.DefaultSequence) with _ExaHyPEMainFileSequence below, which speaks the same construct_output(output, main_name) protocol but fills the file pair with ExaHyPE-flavoured content instead of the mesh-agnostic default.
The generated main() contains only what is specific to the project: the runners, the data types, the domain, the log filter and the load balancing. The runtime configuration, the main loop over the runners and the shutdown are plain C++, i.e. exahype2.configureRuntime(), exahype2.runSimulation() and exahype2.shutdownRuntime().
Definition at line 8 of file DefaultSimulationMain.py.
| exahype2.api.generators.DefaultSimulationMain.DefaultSimulationMain.__init__ | ( | self, | |
| Project | project ) |
Definition at line 31 of file DefaultSimulationMain.py.
References __init__().
Referenced by __init__().


| exahype2.api.generators.DefaultSimulationMain.DefaultSimulationMain.construct_output | ( | self, | |
| peano_project ) |
Add this generator's output to peano_project (a peano4.api.Project-compatible object, or anything else that add()'s cleanly into peano_project.output).
This is the one thing every Generator has to implement.
peano_project: peano4.api.Project The Peano 4 project that self.project.generate_Peano4_project() is currently assembling. It is a local variable there, not an attribute - merely passed through here, so this generator can add its own artefacts to it.
Reimplemented from exahype2.api.Project.Project.Generator.
Definition at line 34 of file DefaultSimulationMain.py.
References exahype2.api.generators.DefaultSimulationMain._ExaHyPEMainFileSequence.project, exahype2.api.generators.KernelMicrobenchmarkMain._ExaHyPEKernelBenchmarkMainFileSequence.project, and exahype2.api.Project.Project.Generator.project.