Commit Graph

11674 Commits

Author SHA1 Message Date
Markus Blatt
3e37b8abe8
Merge pull request #2965 from bska/dont-needlessly-capture-constant
Don't Needlessly Capture Constant Buffer Size
2022-02-24 12:35:39 +01:00
Bård Skaflestad
982ed7caf0 Don't Needlessly Capture Constant Buffer Size
A lambda expression can read the value of a variable without
capturing it if the variable

    has const non-volatile integral or enumeration type and
    has been initialized with a constant expression

Clang issues a diagnostic if such variables are captured so drop the
'sz' from the explicit list of captures.
2022-02-24 09:58:51 +01:00
Bård Skaflestad
a85ec1a7e6
Merge pull request #2964 from atgeirr/fix-missing-include
Add missing <string> include for std::to_string().
2022-02-24 09:51:28 +01:00
Atgeirr Flø Rasmussen
84644fe5cd Add missing <string> include for std::to_string(). 2022-02-24 09:32:17 +01:00
Markus Blatt
555eb4c8b0
Merge pull request #2963 from joakim-hove/get_str_allow_rawstring
Export RawString as std::string to Python
2022-02-23 13:47:28 +01:00
Markus Blatt
9ef9cb0245
Merge pull request #2958 from bska/create-iregflow-summary
Add Summary Evaluation Functions For Inter-Region Flows
2022-02-23 13:41:49 +01:00
Bård Skaflestad
369b6ee637 Add Summary Evaluation Functions For Inter-Region Flows
This commit adds the glue code necessary to extract the pertinent
flow rate values from an inter-region flow rate map and then
accumulating those into the SummaryState.  We multiply with the
timestep size if we're computing a cumulative total volume.

Add basic unit test for this part of Summary::eval().
2022-02-23 11:57:34 +01:00
Joakim Hove
42e36100a8 Export RawString as std::string to Python 2022-02-23 11:01:00 +01:00
Markus Blatt
0475a46ab3
Merge pull request #2961 from bska/fix-welopen-status-event
Update Injected/Produced Flag When Processing WELOPEN
2022-02-22 12:37:01 +01:00
Bård Skaflestad
4150936e7c Update Injected/Produced Flag When Processing WELOPEN
If a well is entered in WCON{INJE,PROD} as status 'SHUT' but later
activated in WELOPEN, we must take care to record this status change
in the well's internal "has_produced" or "has_injected" flags as
appropriate.  Otherwise, the counts of "abandoned" wells will not be
correct.
2022-02-21 22:20:20 +01:00
Bård Skaflestad
0275a00b0f Fix Misspelled Function Name 2022-02-21 22:20:20 +01:00
Bård Skaflestad
31cddd2d86
Merge pull request #2962 from goncalvesmachadoc/btemp
add BTCNFHEA
2022-02-21 22:18:11 +01:00
goncalvesmachadoc
187149dc1a add BTCNFHEA 2022-02-21 17:35:04 +01:00
Markus Blatt
e44f3c6798
Merge pull request #2945 from bska/iregflow-protocol-objects
Add Protocol Objects for Linearising and Accumulating Inter-Region Flows
2022-02-17 09:36:34 +01:00
Bård Skaflestad
819571a8db Make Summary Evaluation API Aware of Inter-Region Flows
This commit adds a new parameter, interreg_flows, to the eval()
member function of class Opm::Summary.  This is in preparation of
adding summary file output of inter-region flow rates and
cumulatives-e.g., the ROFT summary vectors.
2022-02-16 23:28:46 +01:00
Bård Skaflestad
68975be966 Add Accumulating Mapping Structure for Inter-Region Flows
This commit introduces a new helper facility,

    data::InterRegFlowMap

that knows how to interpret region IDs.  It is a simple wrapper
around a common CSR representation of (source, destination) region
ID pairs with the additional feature that the element type of the
connection is a linear sequence values of arithmetic type.  We've
initially elected to make this sequence out of 'float' in order to
conserve memory since we expect to do little arithmetic to the
sequence itself outside of compression and parallel communication.

Client code will be of two primary categories

  1. Producing side which inserts flow rates from individual
     connections, compresses the result when done, and communicates
     the results to one or more parallel I/O ranks

  2. Consuming side, typically on an I/O rank, which merges the
     contributions from multiple source ranks and extracts values
     pertaining inter-region flows for purpose of outputting time
     series data to a summary file.

The first case will create and populate 'FlowRates' and add these
into the container using the 'addConnection' function and finally
call 'compress' when complete.  Consumers will then use member
function 'getInterRegFlows' to extract a signed view of flow rate
values associated to a particular region ID pair (nullopt if no such
pair is registered).
2022-02-16 23:28:46 +01:00
Bård Skaflestad
7ef3d6c0b3 Add Protocol to Linearise Connection Flow Rates Into Subrange
This commit introduces a wrapper for a linear subrange of
consecutive elements of an arithmetic type that imposes an ordering
of the elements when treated as directional component surface flow
rates.  The wrapper distinguishes negative from positive flow rate
contributions and tracks those separately.  This is a building block
for accounting for the inter-region flows in a parallel context.
2022-02-16 23:28:46 +01:00
Bård Skaflestad
27da32d812 Re-Sort Main Source File Section for output/data
In preparation of adding more source files here.
2022-02-16 23:28:46 +01:00
Bård Skaflestad
e6bfc0624c
Merge pull request #2960 from tskille/emsry_rxft_fix
Split summary number for RXFT vectors in ESMRY file
2022-02-16 21:19:16 +01:00
Torbjørn Skille
48cab1f3bf Split summary number for RXFT vectors in ESMRY file 2022-02-16 20:45:01 +01:00
Bård Skaflestad
f9ab536a66
Merge pull request #2959 from bska/improve-skiprest-diagnostic
Clarify Underlying Issue When Missing RESTART DATE in SKIPREST
2022-02-15 14:55:51 +01:00
Bård Skaflestad
ea5b2f072c Clarify Underlying Issue When Missing RESTART DATE in SKIPREST
When a restarted model uses SKIPREST, there must be DATES or TSTEP
records/report times that correspond exactly to the restart time.
The current diagnostic message is a little too brief and developer
centric and does not offer sufficient hints to the user as to what
the underlying issue might be.

Try to expand the current message and provide more clues to the user
by mentioning both the SKIPREST and RESTART keywords in addition to
the expected and encountered time points.

Example original message:
  Error: Problem with keyword DATES
  In PRED_FLOW.DATA line 223
  At date: 2019-04-18 - scanned past restart data: 2019-04-12

Example message in this commit:
  Error: Problem with keyword DATES
  In PRED_FLOW.DATA line 223
  In a restarted simulation using SKIPREST, the DATES keyword must have
  a record corresponding to the RESTART time 12-Apr-2019 00:00:00.
  Reached time 18-Apr-2019 00:00:00 without an intervening record.
2022-02-15 14:08:26 +01:00
Joakim Hove
46c955956f
Merge pull request #2957 from tskille/deck_item_change
DeckItem - API change
2022-02-14 18:31:10 +01:00
Torbjørn Skille
5bf2087d0a DeckItem - API change 2022-02-14 15:48:52 +01:00
Markus Blatt
ab697b69ea
Merge pull request #2916 from joakim-hove/udq-doc
Technical documentation for UDQ / ACTIONX and PYACTION
2022-02-14 15:17:20 +01:00
Joakim Hove
fb012786c3 Address final review comments in pyaction.tex and actionx.tex 2022-02-11 11:31:31 +01:00
Joakim Hove
a8656a9bbd Address final review comments in udq.tex 2022-02-10 07:55:04 +01:00
Joakim Hove
8c95c64e9b PYACTION polish II 2022-02-10 07:25:12 +01:00
Joakim Hove
b8cecd9ce4 Pyaction polish I 2022-02-10 07:25:12 +01:00
Joakim Hove
a62c3ae162 Actionx polish II 2022-02-10 07:25:12 +01:00
Joakim Hove
4e7bcd16b9 Actionx polish I 2022-02-10 07:25:12 +01:00
Joakim Hove
b20baa0c8e UDQ polish II 2022-02-10 07:25:12 +01:00
Joakim Hove
d89f92d52f Polish of UDQ chapter 2022-02-10 07:25:12 +01:00
Joakim Hove
148a54a7a6 Add section about problems with parallel and actionx 2022-02-10 07:25:12 +01:00
Joakim Hove
7d51e996d9 Update information about ACTIONX + WELPI 2022-02-10 07:25:12 +01:00
Joakim Hove
832b351bb3 Edit sentence about wrapping and embedding 2022-02-10 07:25:12 +01:00
Joakim Hove
de3e639196 More about PYACTION security 2022-02-10 07:25:12 +01:00
Joakim Hove
8370bf152a Written more about the ACTIONX + PYACTION interaction 2022-02-10 07:25:12 +01:00
Joakim Hove
b6731ba8c7 Add two \label{..} expressions 2022-02-10 07:25:12 +01:00
Joakim Hove
411682c466 Slightly rewritten paragraph about ACTIONX <-> simulator interaction 2022-02-10 07:25:12 +01:00
Joakim Hove
f869df0255 PYACTION updates 2022-02-10 07:25:12 +01:00
Joakim Hove
8a2c30c7ba More Python doc 2022-02-10 07:25:12 +01:00
Joakim Hove
53dd18a92c Start adding documentation for the PYACTION keyword 2022-02-10 07:25:12 +01:00
Joakim Hove
f61e573a19 Minor formatting 2022-02-10 07:25:12 +01:00
Joakim Hove
fafebfdc5d Fix will -> well 2022-02-10 07:25:12 +01:00
Joakim Hove
ff13b32da0 More about opm-common <-> opm-simulators interaction for Actionx 2022-02-10 07:25:12 +01:00
Joakim Hove
a403a31f16 Add ref to ref manual 2022-02-10 07:25:12 +01:00
Joakim Hove
627faea4e5 More ACTIONX doc work 2022-02-10 07:25:12 +01:00
Joakim Hove
7056c5f879 Changes to ACTIONX section 2022-02-10 07:25:12 +01:00
Joakim Hove
9e78155222 More on actionx execution model 2022-02-10 07:25:12 +01:00