mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Implements a Python step_cleanup() method.
Continues the work in #2735 on implementing Python bindings for the flow simulator.
This commit is contained in:
@@ -335,6 +335,15 @@ namespace Opm
|
||||
return simulator_->runStep(*simtimer_);
|
||||
}
|
||||
|
||||
// Called from Python to cleanup after having executed the last
|
||||
// executeStep()
|
||||
int executeStepsCleanup()
|
||||
{
|
||||
SimulatorReport report = simulator_->finalize();
|
||||
runSimulatorAfterSim_(report);
|
||||
return report.success.exit_status;
|
||||
}
|
||||
|
||||
// Print an ASCII-art header to the PRT and DEBUG files.
|
||||
// \return Whether unkown keywords were seen during parsing.
|
||||
static void printPRTHeader(bool output_cout)
|
||||
|
||||
@@ -35,13 +35,16 @@ public:
|
||||
BlackOilSimulator( const std::string &deckFilename);
|
||||
int run();
|
||||
int step();
|
||||
int step_init();
|
||||
int stepInit();
|
||||
int stepCleanup();
|
||||
|
||||
private:
|
||||
const std::string deckFilename_;
|
||||
bool hasRunInit_;
|
||||
bool hasRunCleanup_;
|
||||
|
||||
std::unique_ptr<FlowMainEbosType> mainEbos_;
|
||||
std::unique_ptr<Opm::Main> main_;
|
||||
bool hasRunInit_;
|
||||
};
|
||||
|
||||
} // namespace Opm::Python
|
||||
|
||||
Reference in New Issue
Block a user