Commit Graph

867 Commits

Author SHA1 Message Date
Bård Skaflestad
ad595fed5e
Merge pull request #5506 from akva2/move_params_to_parameters
Move parameters to Opm::Parameters namespace
2024-08-09 09:16:10 +02:00
Arne Morten Kvarving
f310698fef MPIPacker: move function definition to cpp file 2024-08-07 11:28:15 +02:00
Arne Morten Kvarving
2a52cf8134 changed: Damaris parameters moved to Opm::Parameters namespace 2024-08-06 09:50:02 +02:00
Lisa Julia Nebel
371fbdfc03 Include <boost/version.hpp> before the macro BOOST_VERSION is checked 2024-07-16 17:39:32 +02:00
Lisa Julia Nebel
653cb28bc2 Add the metis partitioner as a command line option as well 2024-07-16 17:39:28 +02:00
Vegard Kippe
fae49636cc Addressing review comments (changed assert to throw, put chunked broadcast in private method) 2024-07-09 19:15:50 +02:00
Vegard Kippe
99d5a147b1 Fix broadcast and initialize int_pos properly.. 2024-07-09 15:02:15 +02:00
Vegard Kippe
c10695c5d5 Switch to using size_t instead of int for buffer position, and properly account for MPI using int 2024-07-09 13:48:04 +02:00
Arne Morten Kvarving
d26ec065f3 add missing include 2024-07-03 11:02:16 +02:00
Arne Morten Kvarving
48344facd4 add virtual destructor to class with virtual members 2024-07-02 22:41:48 +02:00
Bård Skaflestad
0c71d0701c Add MPI Support to Saturation Function Consistency Checks
This commit adds a new public member function

    SatfuncConsistencyChecks<>::collectFailures(root, comm)

which aggregates consistency check violations from all ranks in the
MPI communication object 'comm' onto rank 'root' of 'comm'.  This
amounts to summing the total number of violations from all ranks and
potentially resampling the failure points for reporting purposes.

To this end, extract the body of function processViolation() into a
general helper which performs reservoir sampling and records point
IDs and which uses a call-back function to populate the check values
associated to a single failed check.  Re-implement the original
function in terms of this helper by wrapping exportCheckValues() in
a lambda function.  Extract similar helpers for numPoints() and
anyFailedChecks(), and add a new helper function

    SatfuncConsistencyChecks<>::incorporateRankViolations()

which brings sampled points from an MPI rank into the 'root's
internal data structures.

One caveat applies here.  Our current approach to collecting check
failures implies that calling member function reportFailures() is
safe only on the 'root' process in a parallel run.  On the other
hand functions anyFailedChecks() and anyFailedCriticalChecks() are
safe, and guaranteed to return the same answer, on all MPI ranks.

On a final note, the internal helper functions are at present mostly
implemented in terms of non-owning pointers.  I intend to switch to
using 'std::span<>' once we enable C++20 mode.
2024-06-28 11:04:53 +02:00
Bård Skaflestad
c3939c5444 Add New Platform for Saturation Function Consistency Checks
The intention is that this will ultimately replace the existing
RelpermDiagnostics component which does not really work in parallel
and which does not report enough context to help diagnose underlying
issues.  For now, though, we just add the shell of a new set of
checks and hook that up to the build.

Class SatfuncConsistencyChecks<Scalar> manages a configurable set of
consistency checks, the implementations of which must publicly
derive from SatfuncConsistencyChecks<Scalar>::Check.  Client code
will configure a set of checks by first calling

    SatfuncConsistencyChecks<Scalar>::resetCheckSet()

then register individual checks by calling

    SatfuncConsistencyChecks<Scalar>::addCheck()

and finally build requisite internal structures by calling

    SatfuncConsistencyChecks<Scalar>::finaliseCheckSet()

Client code will then run the checks by calling

    SatfuncConsistencyChecks<Scalar>::checkEndpoints()

typically in a loop.  Class SatfuncConsistencyChecks<Scalar> will
count consistency check failures and attribute these to each
individual check as needed.  We also maintain separate counts for
"Standard" and "Critical" failures.  The former will typically
generate warnings while the latter will typically cause the
simulation run to stop.  Individual checks get to decide which check
is "Critical", and client code gets to decide how to respond to
"Critical" failures.

Member function SatfuncConsistencyChecks<Scalar>::reportFailures()
will generate a textual report of the known set of consistency check
failures at a give severity level.

As an internal implementation detail, SatfuncConsistencyChecks uses
"reservoir sampling"
(https://en.wikipedia.org/wiki/Reservoir_sampling) to track details
about individual failed checks.  We maintain at most a fixed number
of individual points (constructor argument).
2024-06-26 12:17:00 +02:00
Bård Skaflestad
26cd7ab993 Move opm/core/props to opm/simulators/utils
The opm/core directory is no longer meaningful, and it contains only
components which might collectively be described as simulator
utilities.
2024-06-25 12:22:09 +02:00
Markus Blatt
9dbaad2b3e
Merge pull request #5423 from blattms/bugfix/mswell-exceptions-are-problems
Only indicate problems for exceptions whem updating well potentials,
2024-06-20 14:33:17 +02:00
Vegard Kippe
683dc715e2 Do NOT delete files recursively - causes massive problems if outputdir is not specified.. 2024-06-14 13:36:15 +02:00
Markus Blatt
58ede5e789 Only indicate problems for exceptions whem updating well potentials,
Nearly all exceptions throw when computing well potentoals will not
abort the simulator but result in timestep chops. Hence those should not be
counted as errors (e.g. by calling the OPM_*THROW* macros) and be
reported in the PRT file.

This change will cause at least two more  occurences (in
MSWellHelpers) to be treated as problems. For this we added a new
helper function.
2024-06-12 14:25:37 +02:00
Atgeirr Flø Rasmussen
fc906842ad
Merge pull request #5352 from jcbowden/damaris-limit-variables-v1
Add ability to pass multiple variables to Damaris using DamarisWriter class.
2024-06-07 15:54:59 +02:00
Bård Skaflestad
3074c0d9fd Enable WTMULT as an Input Operation
Basic support for this keyword was added in commit

    OPM/opm-common@5e3e20c552

and this commit enables running models which use that basic support.
Advanced uses, such as including user-defined arguments for the
multipliers, will still be rejected at the input level.
2024-06-06 09:14:01 +02:00
josh bowden
7fc6cc0430 Other small additions from github comments and removal of compile time logic that checks for ParaView and Python - makes code more readable and alows use of Damaris libraries with differing compiled in backends to be swapped without need for recompiling opm-simulators 2024-06-05 17:26:34 +02:00
Svenn Tveit
912cd45182 Support for CNAMES needed with CO2STORE 2024-06-03 20:40:26 +02:00
Bård Skaflestad
a3a2b7a978 Make SummaryState Objects Aware of Undefined UDQ Value
This PR switches to calling the SummaryState constructor which is
aware of the value of undefined UDQs (OPM/opm-common#4052) directly.

While here, also sort headers, split some long lines, and prefer
initialisation lists to constructor body assignments.
2024-05-29 09:16:56 +02:00
josh bowden
2744614f9c update after pull request comments; addition of OUTPUTDIR variable to Damaris XML configuration 2024-05-17 17:36:18 +02:00
Arne Morten Kvarving
b74b170d5b fixed: build with dune-fem 2.9 2024-05-16 10:58:08 +02:00
josh bowden
3630177e3e added ability to pass through multiple variables to Damaris, with full list still defined in initDamarisXmlFile.cpp ; Also adds ability to limit the variables to be passed through using --damaris-limit-variables=<CSV list> coammand line option 2024-05-14 21:08:47 +02:00
Vegard Kippe
b27c83b2fd Tag 'BASIC=0' as allowed in RPTRST 2024-05-06 15:17:08 +02:00
Vegard Kippe
b68a55a9b9 Add parameter InputSkipMode to parameterise the behvaviour of the SKIP100 and SKIP300 keywords 2024-05-03 09:28:14 +02:00
Bård Skaflestad
f71c652b0a
Merge pull request #5281 from daavid00/immCO2
Summary for immobile free-phase at saturations for which the nonwetting relative permeability equals zero
2024-04-12 17:06:21 +02:00
David Landa Marban
9671792106 summary for immobile free-phase at saturations for which the nonwetting relative permeability equals zero 2024-04-12 15:31:22 +02:00
Bård Skaflestad
b1be391d4c
Merge pull request #5172 from totto82/gconprod7
Implement WELL as group limit action
2024-04-11 17:36:55 +02:00
Bård Skaflestad
10d2f52cd2 Add Procedure for Calculating Basic FIP Region Statistics
This commit implements the parallel version of

    EclipseState::computeFipRegionStatistics()

which computes a FIPRegionStatistics object for the current run's
fluid-in-place regions.  The object construction uses an MPI-aware
reduction process to compute the maximum region IDs across all MPI
ranks.

While here, also unconditionally form the statistics object as part
of the EclWriter's constructor to ensure that all ranks participate
in the process.  The initial approach of constructing the object on
first use is not robust in parallel.  We may however wish to compute
these statistics only when needed.  If so, that will be the subject
of follow-up work.
2024-04-05 17:06:13 +02:00
Arne Morten Kvarving
0161d69660 adjust to removal of EWOMS_GET_PARAM 2024-04-05 14:02:28 +02:00
Tor Harald Sandve
920ad68782 Implement WELL as group limit action
And remove G as unsupported option in WTEST
2024-04-03 08:51:09 +02:00
Bård Skaflestad
785b96f6f3 Distribute SummaryConfig Objects With eclBroadcast
Suggested by [at]akva2.

While here, also switch to using type deduction instead of explicit
template arguments for the eclBroadcast overloads.
2024-03-22 16:53:51 +01:00
Arne Morten Kvarving
2a2a9f5de4 DamarisKeywords: correct paths in comments 2024-03-08 12:39:48 +01:00
Arne Morten Kvarving
76ccaf45ef ebos/damaris_properties.hh: move to opm/simulators/flow 2024-03-08 12:39:48 +01:00
Arne Morten Kvarving
c9b3de16f1 move ebos/femcpgridcompat.hh to opm/simulators/flow 2024-03-08 12:39:48 +01:00
Bård Skaflestad
553d3c811e Permit DATUMR and DATUMRX Keywords in Input File
Following PRs

  * OPM/opm-common#3958
  * OPM/opm-simulators#5240

these keywords are nominally supported, at least for the block
level summary keywords (BPPx).
2024-03-04 13:50:26 +01:00
Vegard Kippe
45e63bd498 Readability improvement 2024-02-22 13:03:54 +01:00
Vegard Kippe
b14df39503 Update schedule object after it is actually created.. 2024-02-21 21:47:51 +01:00
Vegard Kippe
cd1b0f808b Respect low parsing strictness when reprocessing the schedule section after action application. 2024-02-21 17:02:33 +01:00
Bård Skaflestad
d69ba021a9
Merge pull request #5168 from lisajulia/feature/removeFilesOnSimulationStartup
Feature/remove files on simulation startup
2024-02-08 17:30:07 +01:00
Lisa Julia Nebel
e4080a3fe4 Add 'prepareResultOutputDirectory' function in Opm namespace that removes possible old simulation output files from the specified output directory.
This function is called during 'setupLogging' before the actual logging starts.
2024-02-08 16:08:50 +01:00
Arne Morten Kvarving
d4e311f9e0 fixed: display exception message no matter which rank it occurred on 2024-02-07 14:12:54 +01:00
Markus Blatt
b5ad44bdee
Merge pull request #5161 from totto82/coordssys
Ignore Coordsys and print a warning
2024-02-06 16:19:09 +01:00
Arne Morten Kvarving
ed88fa583c add missing include 2024-02-06 10:41:36 +01:00
Tor Harald Sandve
2ed3f924f2 Ignore Coordsys and print a warning 2024-02-06 09:29:10 +01:00
Arne Morten Kvarving
d6f59c1d4b
Merge pull request #5134 from lisajulia/feature/NONNC
Feature/NONNC
2024-02-01 15:13:58 +01:00
Arne Morten Kvarving
aa37225ad1 GridDataOutput: use implicit std::string constructor 2024-01-30 13:19:13 +01:00
Arne Morten Kvarving
a588d4196d GridDataOutput: avoid stringstream member 2024-01-30 13:19:12 +01:00
Arne Morten Kvarving
54c386ae2c GridDataOutput: add const correctness 2024-01-30 13:19:00 +01:00