mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Extra command line argument write-lodsmry for creating LODSMRY file
- default is false - file LODSRMY optimized for fast loading of selected vectors
This commit is contained in:
parent
bed3114dcd
commit
4e9a19cf7c
@ -163,7 +163,8 @@ EclGenericWriter(const Schedule& schedule,
|
|||||||
const GridView& gridView,
|
const GridView& gridView,
|
||||||
const Dune::CartesianIndexMapper<Grid>& cartMapper,
|
const Dune::CartesianIndexMapper<Grid>& cartMapper,
|
||||||
const Dune::CartesianIndexMapper<EquilGrid>* equilCartMapper,
|
const Dune::CartesianIndexMapper<EquilGrid>* equilCartMapper,
|
||||||
bool enableAsyncOutput)
|
bool enableAsyncOutput,
|
||||||
|
bool enableEsmry )
|
||||||
: collectToIORank_(grid,
|
: collectToIORank_(grid,
|
||||||
equilGrid,
|
equilGrid,
|
||||||
gridView,
|
gridView,
|
||||||
@ -182,7 +183,7 @@ EclGenericWriter(const Schedule& schedule,
|
|||||||
eclIO_.reset(new EclipseIO(eclState_,
|
eclIO_.reset(new EclipseIO(eclState_,
|
||||||
UgGridHelpers::createEclipseGrid(*equilGrid, eclState_.getInputGrid()),
|
UgGridHelpers::createEclipseGrid(*equilGrid, eclState_.getInputGrid()),
|
||||||
schedule_,
|
schedule_,
|
||||||
summaryConfig_));
|
summaryConfig_, "", enableEsmry));
|
||||||
|
|
||||||
const auto& wbp_calculators = eclIO_->summary().wbp_calculators( schedule.size() - 1 );
|
const auto& wbp_calculators = eclIO_->summary().wbp_calculators( schedule.size() - 1 );
|
||||||
wbp_index_list_ = wbp_calculators.index_list();
|
wbp_index_list_ = wbp_calculators.index_list();
|
||||||
|
@ -69,7 +69,8 @@ public:
|
|||||||
const GridView& gridView,
|
const GridView& gridView,
|
||||||
const Dune::CartesianIndexMapper<Grid>& cartMapper,
|
const Dune::CartesianIndexMapper<Grid>& cartMapper,
|
||||||
const Dune::CartesianIndexMapper<EquilGrid>* equilCartMapper,
|
const Dune::CartesianIndexMapper<EquilGrid>* equilCartMapper,
|
||||||
bool enableAsyncOutput);
|
bool enableAsyncOutput,
|
||||||
|
bool enableEsmry);
|
||||||
|
|
||||||
const EclipseIO& eclIO() const;
|
const EclipseIO& eclIO() const;
|
||||||
|
|
||||||
|
@ -437,6 +437,11 @@ template<class TypeTag>
|
|||||||
struct EnableAsyncEclOutput<TypeTag, TTag::EclBaseProblem> {
|
struct EnableAsyncEclOutput<TypeTag, TTag::EclBaseProblem> {
|
||||||
static constexpr bool value = true;
|
static constexpr bool value = true;
|
||||||
};
|
};
|
||||||
|
// Write ESMRY file for fast loading of summary data
|
||||||
|
template<class TypeTag>
|
||||||
|
struct EnableEsmry<TypeTag, TTag::EclBaseProblem> {
|
||||||
|
static constexpr bool value = false;
|
||||||
|
};
|
||||||
|
|
||||||
// By default, use single precision for the ECL formated results
|
// By default, use single precision for the ECL formated results
|
||||||
template<class TypeTag>
|
template<class TypeTag>
|
||||||
@ -2544,7 +2549,7 @@ private:
|
|||||||
if (FluidSystem::phaseIsActive(FluidSystem::waterPhaseIdx))
|
if (FluidSystem::phaseIsActive(FluidSystem::waterPhaseIdx))
|
||||||
dofFluidState.setSaturation(FluidSystem::waterPhaseIdx,
|
dofFluidState.setSaturation(FluidSystem::waterPhaseIdx,
|
||||||
waterSaturationData[dofIdx]);
|
waterSaturationData[dofIdx]);
|
||||||
|
|
||||||
if (FluidSystem::phaseIsActive(FluidSystem::gasPhaseIdx)){
|
if (FluidSystem::phaseIsActive(FluidSystem::gasPhaseIdx)){
|
||||||
if (!FluidSystem::phaseIsActive(FluidSystem::oilPhaseIdx)){
|
if (!FluidSystem::phaseIsActive(FluidSystem::oilPhaseIdx)){
|
||||||
dofFluidState.setSaturation(FluidSystem::gasPhaseIdx,
|
dofFluidState.setSaturation(FluidSystem::gasPhaseIdx,
|
||||||
|
@ -53,6 +53,10 @@ template<class TypeTag, class MyTypeTag>
|
|||||||
struct EclOutputDoublePrecision {
|
struct EclOutputDoublePrecision {
|
||||||
using type = UndefinedProperty;
|
using type = UndefinedProperty;
|
||||||
};
|
};
|
||||||
|
template<class TypeTag, class MyTypeTag>
|
||||||
|
struct EnableEsmry {
|
||||||
|
using type = UndefinedProperty;
|
||||||
|
};
|
||||||
|
|
||||||
} // namespace Opm::Properties
|
} // namespace Opm::Properties
|
||||||
|
|
||||||
@ -108,6 +112,8 @@ public:
|
|||||||
|
|
||||||
EWOMS_REGISTER_PARAM(TypeTag, bool, EnableAsyncEclOutput,
|
EWOMS_REGISTER_PARAM(TypeTag, bool, EnableAsyncEclOutput,
|
||||||
"Write the ECL-formated results in a non-blocking way (i.e., using a separate thread).");
|
"Write the ECL-formated results in a non-blocking way (i.e., using a separate thread).");
|
||||||
|
EWOMS_REGISTER_PARAM(TypeTag, bool, EnableEsmry,
|
||||||
|
"Write ESMRY file for fast loading of summary data.");
|
||||||
}
|
}
|
||||||
|
|
||||||
// The Simulator object should preferably have been const - the
|
// The Simulator object should preferably have been const - the
|
||||||
@ -122,7 +128,7 @@ public:
|
|||||||
simulator.vanguard().gridView(),
|
simulator.vanguard().gridView(),
|
||||||
simulator.vanguard().cartesianIndexMapper(),
|
simulator.vanguard().cartesianIndexMapper(),
|
||||||
simulator.vanguard().grid().comm().rank() == 0 ? &simulator.vanguard().equilCartesianIndexMapper() : nullptr,
|
simulator.vanguard().grid().comm().rank() == 0 ? &simulator.vanguard().equilCartesianIndexMapper() : nullptr,
|
||||||
EWOMS_GET_PARAM(TypeTag, bool, EnableAsyncEclOutput))
|
EWOMS_GET_PARAM(TypeTag, bool, EnableAsyncEclOutput), EWOMS_GET_PARAM(TypeTag, bool, EnableEsmry))
|
||||||
, simulator_(simulator)
|
, simulator_(simulator)
|
||||||
{
|
{
|
||||||
this->eclOutputModule_ = std::make_unique<EclOutputBlackOilModule<TypeTag>>(simulator, this->wbp_index_list_, this->collectToIORank_);
|
this->eclOutputModule_ = std::make_unique<EclOutputBlackOilModule<TypeTag>>(simulator, this->wbp_index_list_, this->collectToIORank_);
|
||||||
|
Loading…
Reference in New Issue
Block a user