Commit Graph

20 Commits

Author SHA1 Message Date
Arne Morten Kvarving
240c039f53 readDeck: make the ErrorGuard an internal detail 2023-01-17 13:30:39 +01:00
Arne Morten Kvarving
56df430bd6 readDeck: make the ParseContext an internal detail 2023-01-17 09:36:31 +01:00
Arne Morten Kvarving
60b23e8bb1 move ParseContext configuration to readDeck
this way we do not need to include InputErrorAction in Main.hpp
2023-01-16 22:17:39 +01:00
Arne Morten Kvarving
c7016854d9 changed: make the deck an implementation detail in Opm::readDeck 2022-11-24 13:00:38 +01:00
Atgeirr Flø Rasmussen
926c213628 Make ensureOutputDirExists() callable outside readDeck.cpp, and use it.
This is necessary because when using Damaris we must have the output dir ready
when we initialize Damaris. In the existing code, this was ensured only
from the setupLogging() call.
2022-10-13 12:23:06 +02:00
Bård Skaflestad
dfdfbbd7d7 Don't Process Corner-Point Data If No Valid Cell Geometry
If no cell has a valid corner-point geometry, typically caused by
using GDFILE to read non-finite data such as all ZCORN = -1.0E+20,
then we must not attempt to generate a grid structure.  If we do, we
will typically just fail somewhere deep down in the corner-point
processing code and generate a diagnostic message that's hard to
decipher.

With this commit we instead output a diagnostic message of the form

    Failed to create valid EclipseState object.
    Exception caught: No active cell in input grid has valid/finite cell geometry
    Please check geometry keywords, especially if grid is imported through GDFILE

This may not be a lot better than the original diagnostic

    Processing grid
    flow: ${ROOT}/opm-grid/opm/grid/cpgpreprocess/preprocess.c:768: is_lefthanded: Assertion `! searching' failed.
    Aborted (core dumped)

but does at least suggest that the grid data may be faulty.
2022-03-25 14:35:55 +01:00
Markus Blatt
710d648eda Prevent multiple *.?.dbg/prt files in production crashed parallel runs.
There was a fallout when skipping concating these files to the
default ones (PR #1708). We should also have deactivated creating
these files at all. As a result these files appeared in all parallel
runs that were aborted.

This change now prevents creating and logging to these files in
parallel in a default
run (--enable-parallel-logging-fallout-warning=false).

Developers can still activate logging and concating to see whether
everything is only logged on the io process by passing
--enable-parallel-logging-fallout-warning=true.

Closes 3725
2022-01-27 17:21:29 +01:00
Joakim Hove
2c68f12769 Load WellTestState from restart file 2021-10-13 08:46:48 +02:00
Bård Skaflestad
1feab761d6 Extract Helper Functions From readDeck
Mostly to reduce the number of nested conditionals and long lines.
2021-10-07 22:01:47 +02:00
Elyes Ahmed
0202b00d59 clean up after review 2021-10-05 13:07:52 +02:00
Elyes Ahmed
f53c597f90 Replacing use of MPI_COMM_WORLD with a variable communicator. 2021-10-05 13:07:52 +02:00
Håkon Hægland
5ad65c70ee Initialize blackoil simulator from schedule shared with Python.
Adds a new constructor to Main.hpp that takes shared pointers to Deck,
EclipseState, Schedule, and SummaryConfig. This makes it possible to
share these variables with Python without worrying about lifetime issues
of the underlying C++ objects. For example, a Python script can first
create an opm.io.schedule.Schedule object which is modified from Python.
Then, assume the same Python script creates an
opm.simulators.BlackOilSimulator which is initialized with the same
schedule object. Since the underlying C++ object is a shared pointer,
the Schedule object in Python may go out of scope (get deleted by Python)
without having the C++ schedule object being deleted. And the Python
BlackOilSimulator may continue to be used after the Python Schedule object
has been deleted since it still has a valid C++ schedule object.
2021-09-21 15:52:59 +02:00
Joakim Hove
357540bfca Create Action::State external to the vanguard 2021-09-19 10:17:58 +02:00
Joakim Hove
528078e8e1 Assemble UDQState external to the vanguard 2021-07-01 08:24:59 +02:00
Arne Morten Kvarving
a4c0af09d9 fixed: do not use Opm:: prefix when inside namespace Opm 2021-05-05 11:59:18 +02:00
Arne Morten Kvarving
5fb5f79318 readDeck: use forwarding 2021-04-29 12:43:51 +02:00
Joakim Hove
ec344d555d Pass ouput interval overeride to Schedule constructor 2021-03-08 19:30:58 +01:00
Arne Morten Kvarving
76c63c4405 changed: hide internal method 2020-09-15 10:51:57 +02:00
Markus Blatt
c958034d26 Adapt and use readDeck from EclipseBaseVanguard, too.
This reduces code duplication ad should fix the bad_cast exception
when running ebos in parallel.
2020-08-27 09:05:09 +02:00
Markus Blatt
575245d785 Factored out logging setup and deck reading from class Main.
These codes are reimplemented in the ebos simulator and should
be reused, instead. This commit factilitates this and starts
reusing the logging setup code in ebos. Hence reduces code duplication.
2020-08-27 09:05:09 +02:00