Commit Graph

6632 Commits

Author SHA1 Message Date
Bård Skaflestad
1db06277ce
Merge pull request #1088 from bska/further-decouple-from-libecl
Further Decouple OPM-Common From libecl
2019-10-14 08:12:40 -05:00
Joakim Hove
8576bf5809
Merge pull request #1093 from stefoss23/python_unit_system
python: added class UnitSystem.
2019-10-14 14:03:18 +02:00
Bård Skaflestad
662e44683c INTEHEAD Test: Initialize Maximum Number of Wells in Field
Fixes a warning about missing initializers.
2019-10-14 06:14:09 -05:00
Bård Skaflestad
411da1d8a5 Make 'test_Restart' Mostly Independent of libecl
In particular, swith to using class EclIO::ERst to read the files
produced by RestartIO::save().
2019-10-14 06:13:38 -05:00
Bård Skaflestad
3802b4574a Make 'test_Summary' Independent of LibeECL
This commit switches the 'test_Summary' unit test to use class ESmry
for inspecting the values output to disk by 'out::Summary'.  As a
consequence, we are not able to verify units of measure for the
parameters, at least not for the time being.  Moreover, class ESmry
exclusively uses the "i,j,k" sub-key for block-related parameters so
switch those to reference the IJK identifiers.

Finally, as class ESmry currently does not support reading separate
(multiple) summary files, switch the input decks to generate unified
output.
2019-10-14 06:13:38 -05:00
Bård Skaflestad
c013639b51 Make Most Unit Tests Independent of LibECL
This commit switches a set of OPM-Common's unit tests away from
using direct calls to libecl functions and into using base types
from OPM-Common itself (along with Boost.Filesystem).

In particular summary related queries are replaced by calls to ESmry
member functions (wrapped in libecl-like interfaces to minimise code
changes).  We disable checks on unit strings since ESmry currently
does not have a way of associating those with individual variables.
2019-10-14 06:13:38 -05:00
Bård Skaflestad
bcfe700461 Decouple Most of OPM-Common From LibECL
This commit takes a pass at the implementation files in opm-common
and removes references to libecl functions where practical.  In
particular we switch to using types from C++'s standard library (and
Boost.Filesystem) to achieve the effects of the interfaces being
replaced.

We also insert direct calls to Posix function fnmatch() to preserve
existing pattern matching behaviour (well lists and well templates).
2019-10-14 06:13:38 -05:00
Bård Skaflestad
d84b7e19ee ESmry: Add Way of Retrieving Ministep Index at Start of Report Step
This commit introduces a new member function

    int ESmry::miniStepIdxAtReportStep(rptStep)

which returns the zero-based ministep corresponding to the start of
the given report step (one-based indexing).  This will simplify
decoupling a few unit tests from libecl.
2019-10-14 06:13:38 -05:00
Atgeirr Flø Rasmussen
d4cfa5127f
Merge pull request #1097 from akva2/enable_flow_variants
changed: build flow variants on jenkins
2019-10-14 12:59:30 +02:00
Steinar Foss
a089f9ff47 CMakeLists_files.cmake added unit_system to EMBEDDED_PYTHON. 2019-10-14 12:54:17 +02:00
Joakim Hove
87362c1336
Merge pull request #1095 from joakim-hove/inner-exc
Rephrased error message
2019-10-14 12:50:55 +02:00
Joakim Hove
635071d492
Merge pull request #1082 from bska/new-summary-writer
New summary writer
2019-10-14 12:25:44 +02:00
Joakim Hove
2d4f941718
Merge pull request #1096 from akva2/janitoring
Some janitoring
2019-10-14 12:19:13 +02:00
Arne Morten Kvarving
9b44a8f5ce changed: build flow variants on jenkins 2019-10-14 11:06:42 +02:00
Arne Morten Kvarving
4e720c5d74 remove noop explicit template instantation after specialization 2019-10-14 08:54:05 +02:00
Arne Morten Kvarving
d98518c023 avoid returning uninitialized result if wrong indices are given 2019-10-14 08:53:44 +02:00
Arne Morten Kvarving
b0273485c7 remove unused assignment 2019-10-14 08:53:33 +02:00
Arne Morten Kvarving
463d9eb53d remove unused initialization 2019-10-14 08:53:12 +02:00
Arne Morten Kvarving
11462f7618 add missing initializer 2019-10-14 08:36:42 +02:00
Arne Morten Kvarving
73866b97f2 remove unused variable 2019-10-14 08:36:36 +02:00
Arne Morten Kvarving
8979fe25af remove unused function 2019-10-14 08:36:26 +02:00
Steinar Foss
a2a016951f python unit_system name. 2019-10-13 22:53:56 +02:00
Bård Skaflestad
2eb3a06024 Replace Writer for Summary/SMSPEC Files
This commit replaces the existing system for writing summary and
specification (SMSPEC) files with a new implementation based on
class EclOutput.  We package the evaluators of individual parameters
in a set of classes determined by the parameter's category which
each implement a virtual 'update()' function.  This update function
ultimately writes new values into a SummaryState object.

Add a factory-like system for instantiating the appropriate class
depending on a SummaryNode's 'category()'.  Also, add a helper class
for managing the parameters that a configured in a simulation
model's SUMMARY section in order to distinguish these from those
parameters that are merely needed for restart purposes.  The summary
class's 'eval()' function then becomes a loop over the evaluators
for parameters in SUMMARY followed by a loop over the evaluators for
restart vectors.

We reimplement the 'internal_store()' function in terms of an
std::vector of a helper structure 'MiniStep' which holds a ministep
ID (contiguous counter started at zero), a report step ID, and all
the evaluated parameters of this ministep.  The final write function
then consists of outputting those ministep structures that have
accumulated since the previous call to write().  If a simulation
does not call write at all, then this will accumulate all parameters
for all ministeps throughout the simulation history.

We create the SMSPEC file at most once, and write to it at most each
report step.  We create the summary file once (if unified) or at
each report step (if separate).
2019-10-12 20:21:17 -05:00
Bård Skaflestad
7d11a59197 SMSPEC: Temporarily Restore Unconditional RESTART Vector
Needed to ensure we create the same summary/specification files as
the existing system.  We will revert this change once the new system
is in place and we can afford to update the reference solutions.
2019-10-12 18:38:20 -05:00
Joakim Hove
8409c205ae Rephrased error message 2019-10-12 08:04:37 +02:00
Steinar Foss
a177d3b887 python/cxx/export.hpp: rearranged UnitSystem position. 2019-10-11 22:40:35 +02:00
Steinar Foss
c0bd19c59e python: added class UnitSystem. 2019-10-11 22:02:54 +02:00
Joakim Hove
32ac0034a7
Merge pull request #1091 from stefoss23/deck_keyword_vector
deckkeyword: new constructors takes (ParserKeyword, std::vector).
2019-10-11 20:04:50 +02:00
Steinar Foss
17f246c1a7 deckkeyword: new constructors takes (ParserKeyword, std::vector).
DeckKeyword: test for vector<int> data constructor.

DeckKeyword takes std::vector<int> and std::vector<double>.

...

...

...

...
2019-10-11 13:47:14 +02:00
Joakim Hove
d66f0a664c
Merge pull request #1067 from joakim-hove/box-grid
Consider active cells in BOX implementation
2019-10-11 10:57:39 +02:00
Joakim Hove
9af248f889
Merge pull request #1072 from stefoss23/python_deck_values
python: new DeckKeyword constructor takes DeckRecords
2019-10-11 10:57:14 +02:00
Joakim Hove
3c26314475
Merge pull request #1087 from bska/bypass-filleps-for-2p
INIT File: Bypass FILLEPS for Two-Phase Systems
2019-10-11 10:56:25 +02:00
Joakim Hove
12e2c9c545
Merge pull request #1081 from bska/prepare-new-summary-writer
Prepare New Summary Writer
2019-10-11 10:39:59 +02:00
Joakim Hove
79d3f236c2
Merge pull request #1086 from stefoss23/python_conn
Python: removed properties.py, shedule.py, parser_module.py and sunbeam.py
2019-10-11 08:42:07 +02:00
Joakim Hove
5c280ed72a
Merge pull request #1083 from joakim-hove/T
Keywords on starting with T
2019-10-11 08:39:19 +02:00
Joakim Hove
73cc9cff3a
Merge pull request #1085 from stefoss23/add_keywords_H
Adding keywords beginning w/ H and I.
2019-10-11 08:39:07 +02:00
Bård Skaflestad
c736e71e46 INIT File: Bypass FILLEPS for Two-Phase Systems
Flow's saturation function finalizers don't currently handle models
with fewer than three active phases.  Don't attempt to fill in
scaled endpoint vectors in this case, but issue a warning that we're
ignoring FILLEPS here.
2019-10-10 22:28:41 -05:00
Steinar Foss
92f69d7648 removed sunbeam.py. 2019-10-10 12:57:49 +02:00
Steinar Foss
bad1b1d3fb removed parser_module.py. 2019-10-10 12:56:51 +02:00
Steinar Foss
0e1339e648 removed all test suppoert for parser_module.py. 2019-10-10 12:54:22 +02:00
Steinar Foss
3cc205ee93 ELIMINATED 'properties.py'. 2019-10-10 12:54:22 +02:00
Steinar Foss
ad564ad651 python connection: exposed directly via pybind11.
python connection. added property pos.

removed shedule.py.

test_connection.py passed.

test_wells.py: test_completion passes.

removed opm.io.config.

renamed test_state2.py -> test_state.py.
2019-10-10 12:54:40 +02:00
Steinar Foss
39c1056c87 added keywords beginning w/ H and I.
added keywords HMWELCON, HMWPIMPLT.

added keyword HMxxxxxx.

added keywords HRFIN, HWKRO, HWKRORH.

added keywords HWKRORW, HWKRWM HWKRWR.

added keyword HWPCW.

added keywords HWSNUM, HWSOGCR, HWSOWCR.

added keyword HWSWCR.

added keywords HWSWL, HWSWLPC, HWSWU.

added keywords HXFIN, HYDRHEAD, HYFIN.

added keywords HYMOBGDR, HYST, HYSTCHCK.

added keyword HZFIN.

added keywords IHOST, IMBNUMMF, IMPCVD.

IMPLICIT, IMPORT, IMSPCVD.

added keywords INSPEC, INTPC, IONROCK.

added keywords IONXROCK, IONXSURF.

...
2019-10-09 15:29:48 +02:00
Joakim Hove
9f1858265a Create ParserKeywords in try catch block 2019-10-09 11:53:25 +02:00
Joakim Hove
5a9f5c0999 Keywords on starting with T 2019-10-09 08:10:50 +02:00
Bård Skaflestad
a5d943fd8f Unit System: Use Plural for TIME Names
The summary file must have DAYS (&c) for its TIME vector unit.  This
is a step towards enabling new summary writer functionality.

Update the RFT writer accordingly.
2019-10-08 23:25:48 -05:00
Bård Skaflestad
e598aa8cae Output Stream: Add File Creation for Summary Files
This commit adds a single function, createSummaryFile, that opens an
EclOutput object on a file named as an ECLIPSE summary file
(formatted vs. unformatted, unified vs. separate) and returns a
unique_ptr to this.

This is a step towards enabling new summary writer functionality.
2019-10-08 23:20:39 -05:00
Bård Skaflestad
359558536e Output: Support More Than 10,000 Report Steps
This commit extends Flow's support for separate restart files to
more than 10,000 report steps (not necessarily restart steps).  In
particular, add support for generating separate restart files named

    CASE.X000n, CASE.Y000n, CASE.Z000n (unformatted)
    CASE.F000n, CASE.G000n, CASE.H000n (formatted)

This is mostly for completeness.  We do not really expect to run
simulation models with more than 10,000 (or 20,000) report steps.
2019-10-08 23:12:37 -05:00
Bård Skaflestad
e6e8b070d7
Merge pull request #1077 from joakim-hove/compile-fixup
Compile fixup
2019-10-08 17:36:51 -05:00
Joakim Hove
278f4ff3c9
Merge pull request #1079 from stefoss23/python_context_recovery
python: rewrite of tests using ParseContext.
2019-10-08 23:42:44 +02:00