Skip to content

Commit 09b1e47

Browse files
author
Yngve S. Kristiansen
committed
Migrate time map / refcase dependent observations
1 parent b238bab commit 09b1e47

40 files changed

Lines changed: 4079 additions & 5575 deletions

docs/ert/reference/configuration/data_types.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -432,8 +432,7 @@ multiple vectors:
432432
SUMMARY FOPT FOPR FWPR
433433
SUMMARY GGPR:NORTH GOPR:SOUTH
434434

435-
If you in the observation use the ``SUMMARY_OBSERVATION`` or
436-
``HISTORY_OBSERVATION`` keyword to compare simulations and observations for a
435+
If you in the observation use the ``SUMMARY_OBSERVATION`` to compare simulations and observations for a
437436
particular summary vector you need to add this vector after SUMMARY in the ERT
438437
configuration to have it plotted.
439438

docs/ert/reference/configuration/keywords.rst

Lines changed: 0 additions & 112 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ Keyword name Required
3939
:ref:`GEN_DATA <gen_data>` NO Specify a general type of data created/updated by the forward model
4040
:ref:`GEN_KW <gen_kw>` NO Add a scalar parameter
4141
:ref:`GRID <grid>` NO Provide an ECLIPSE grid for the reservoir model
42-
:ref:`HISTORY_SOURCE <history_source>` NO REFCASE_HISTORY Source used for historical values
4342
:ref:`HOOK_WORKFLOW <hook_workflow>` NO Install a workflow to be run automatically
4443
:ref:`INCLUDE <include>` NO Include contents from another ert config
4544
:ref:`INSTALL_JOB <install_job>` NO Install a job for use in a forward model
@@ -60,7 +59,6 @@ Keyword name Required
6059
:ref:`QUEUE_OPTION <queue_option>` NO Set options for an ERT queue system
6160
:ref:`QUEUE_SYSTEM <queue_system>` NO LOCAL_DRIVER System used for running simulation jobs
6261
:ref:`REALIZATION_MEMORY <realization_memory>` NO Set the expected memory requirements for a realization
63-
:ref:`REFCASE <refcase>` NO Reference case used for observations and plotting (See HISTORY_SOURCE and SUMMARY)
6462
:ref:`RUNPATH <runpath>` NO realization-<IENS>/iter-<ITER> Directory to run simulations; simulations/realization-<IENS>/iter-<ITER>
6563
:ref:`RUNPATH_FILE <runpath_file>` NO .ert_runpath_list Name of file with path for all forward models that ERT has run. To be used by user defined scripts to find the realizations
6664
:ref:`RUN_TEMPLATE <run_template>` NO Install arbitrary files in the runpath directory
@@ -69,7 +67,6 @@ Keyword name Required
6967
:ref:`SUBMIT_SLEEP <submit_sleep>` NO 0.0 Determines for how long in seconds the system will sleep between submitting jobs.
7068
:ref:`SUMMARY <summary>` NO Add summary vectors for internalization
7169
:ref:`SURFACE <surface>` NO Surface parameter read from RMS IRAP file
72-
:ref:`TIME_MAP <time_map>` NO Ability to manually enter a list of dates to establish report step <-> dates mapping
7370
:ref:`UPDATE_LOG_PATH <update_log_path>` NO update_log Summary of the update steps are stored in this directory
7471
:ref:`WORKFLOW_JOB_DIRECTORY <workflow_job_directory>` NO Directory containing workflow jobs
7572
===================================================================== ====================================== ============================== ==============================================================================================================================================
@@ -554,83 +551,6 @@ ENSPATH is set to "storage".
554551

555552
The ENSPATH keyword is optional.
556553

557-
558-
.. _history_source:
559-
560-
HISTORY_SOURCE
561-
--------------
562-
563-
In the observation configuration file you can enter
564-
observations with the keyword HISTORY_OBSERVATION; this means
565-
that ERT will extract observed values from the model
566-
historical summary vectors of the reference case. What source
567-
to use for the historical values can be controlled with the
568-
HISTORY_SOURCE keyword. The different possible values for the
569-
HISTORY_SOURCE keyword are:
570-
571-
572-
REFCASE_HISTORY
573-
This is the default value for HISTORY_SOURCE,
574-
ERT will fetch the historical values from the *xxxH*
575-
keywords in the refcase summary, e.g. observations of
576-
WGOR:OP_1 is based the WGORH:OP_1 vector from the
577-
refcase summary.
578-
579-
REFCASE_SIMULATED
580-
In this case the historical values are based on the
581-
simulated values from the refcase, this is mostly relevant when you want
582-
compare with another case which serves as 'the truth'.
583-
584-
When setting HISTORY_SOURCE to either REFCASE_SIMULATED or REFCASE_HISTORY you
585-
must also set the REFCASE variable to point to the ECLIPSE data file in an
586-
existing reference case (should be created with the same schedule file as you
587-
are using now).
588-
589-
*Example:*
590-
591-
::
592-
593-
-- Use historic data from reference case
594-
HISTORY_SOURCE REFCASE_HISTORY
595-
REFCASE /somefolder/ECLIPSE.DATA
596-
597-
The HISTORY_SOURCE keyword is optional.
598-
599-
.. _refcase:
600-
601-
REFCASE
602-
-------
603-
604-
The REFCASE key is used to provide ERT an existing ECLIPSE simulation
605-
from which it can read various information at startup. The intention is
606-
to ease the configuration needs for the user. Functionality provided with the
607-
refcase:
608-
609-
* extract observed values from the refcase using the
610-
:ref:`HISTORY_OBSERVATION <HISTORY_OBSERVATION>` and
611-
:ref:`HISTORY_SOURCE <HISTORY_SOURCE>` keys.
612-
613-
614-
The REFCASE keyword should point to an existing ECLIPSE simulation;
615-
ert will then look up and load the corresponding summary results.
616-
617-
*Example:*
618-
619-
::
620-
621-
-- The REFCASE keyword points to the datafile of an existing ECLIPSE simulation.
622-
REFCASE /path/to/somewhere/SIM_01_BASE.DATA
623-
624-
625-
The refcase is used when loading HISTORY_OBSERVATION and in some scenarios when using SUMMARY_OBSERVATION.
626-
With HISTORY_OBSERVATION the values are read directly from the REFCASE. When using
627-
SUMMARY_OBSERVATION the REFCASE is not strictly required. If using DATE in the observation
628-
configuration the REFCASE can be omitted, and the observation will be compared with the summary
629-
response configured with ECLBASE. If REFCASE is provided it will validated that the DATE
630-
exists in the REFCASE, and if there is a mismatch a configuration error will be raised.
631-
If using HOURS, DAYS, or RESTART in the observation configuration, the REFCASE is required and will
632-
be used to look up the date of the observation in the REFCASE.
633-
634554
.. _install_job:
635555

636556
INSTALL_JOB
@@ -684,9 +604,6 @@ The OBS_CONFIG key should point to a file defining observations and associated
684604
uncertainties. The file should be in plain text and formatted according to the
685605
guidelines given in :ref:`Creating an observation file for use with ERT<Configuring_observations_for_ERT>`.
686606

687-
If you include HISTORY_OBSERVATION in the observation file, you must
688-
provide a reference Eclipse case through the REFCASE keyword.
689-
690607
*Example:*
691608

692609
::
@@ -1794,35 +1711,6 @@ be required to fully understand their effect. Moreover, many of these keywords
17941711
are defined in the site configuration, and thus optional to set for the user,
17951712
but required when installing ERT at a new site.
17961713

1797-
.. _time_map:
1798-
1799-
TIME_MAP
1800-
--------
1801-
1802-
Normally the mapping between report steps and true dates is inferred by
1803-
ERT indirectly by loading the ECLIPSE summary files. In cases where you
1804-
do not have any ECLIPSE summary files you can use the TIME_MAP keyword
1805-
to specify a file with dates which are used to establish this mapping.
1806-
This is only needed in cases where GEN_OBSERVATION is used with the
1807-
DATE keyword, or cases with SUMMARY observations without REFCASE.
1808-
1809-
*Example:*
1810-
1811-
::
1812-
1813-
-- Load a list of dates from external file: "time_map.txt"
1814-
TIME_MAP time_map.txt
1815-
1816-
The format of the TIME_MAP file should just be a list of dates formatted as
1817-
YYYY-MM-DD. The example file below has four dates:
1818-
1819-
::
1820-
1821-
2000-01-01
1822-
2000-07-01
1823-
2001-01-01
1824-
2001-07-01
1825-
18261714
.. _keywords_related_to_running_the_forward_model:
18271715

18281716
Keywords related to running the forward model

docs/ert/reference/configuration/observations.rst

Lines changed: 14 additions & 108 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,6 @@ to this observation file is declared in the main ERT config file using the
2323
The observation file is a plain text file, and is in essence built around three
2424
different classes of observations using the associated keywords:
2525

26-
- :ref:`HISTORY_OBSERVATION <history_observation>`: For time series of
27-
observations for which the observed values can be extracted from the
28-
:term:`summary files` of the :ref:`refcase`. Used for easy / quick
29-
configuration of production rates and fractions.
30-
3126
- :ref:`SUMMARY_OBSERVATION <summary_observation>`: For explicitly giving
3227
scalar observation values for responses that can be extracted from a
3328
reservoir simulator :term:`summary files`. Examples are rates from separator
@@ -120,70 +115,13 @@ Here are two examples:
120115
KEY = GOPR:NESS;
121116
};
122117
123-
124-
.. _history_observation:
125-
126-
HISTORY_OBSERVATION keyword
127-
---------------------------
128-
129-
The keyword HISTORY_OBSERVATION is used to condition on observations fetched
130-
from the :ref:`refcase`. The keyword is typically used to condition
131-
on production and injection rates for groups and wells, as well as bottom hole
132-
and tubing head pressures. An observation entered with the HISTORY_OBSERVATION
133-
keyword will be active at all report steps where data for the observation can
134-
be found.
135-
136-
In its simplest form, a history observation is created as follows::
137-
138-
HISTORY_OBSERVATION WOPR:P1;
139-
140-
This will condition on ``WOPR`` in well P1 using a default observation
141-
error.
142-
143-
By default, this will not extract the simulated values for the vector ``WOPR:P1``
144-
from :ref:`refcase`, but rather the corresponding history values: ``WOPRH:P1``
145-
(see `OPM Flow manual`_ table 11.4 "Fifth Character"). This can changed to
146-
fetch ``WOPR:P1`` instead with the :ref:`history_source` keyword.
147-
148-
In general, a :term:`summary key` is given following the
149-
HISTORY_OBSERVATION keyword, e.g. to condition on variable VAR in well or group
150-
WGNAME, use::
151-
152-
HISTORY_OBSERVATION VAR:WGNAME;
153-
154-
Note that there must be a colon ":" between VAR and WGNAME and that
155-
the statement shall end with a semi-colon ";". Thus, to condition on
156-
WOPR, WWCT and WGOR in well C-17, and for the GOPR for the whole
157-
field, one would add the following to the observation configuration:
158-
159-
.. code-block:: none
160-
161-
HISTORY_OBSERVATION WOPR:C-17;
162-
HISTORY_OBSERVATION WWCT:C-17;
163-
HISTORY_OBSERVATION WGOR:C-17;
164-
165-
HISTORY_OBSERVATION GOPR:FIELD;
166-
167-
The default observation error is the sum between a relative error of 10% to
168-
the measurement and a minimum error of 0.10, which is equivalent to:
169-
170-
.. code-block:: none
171-
172-
HISTORY_OBSERVATION GWIR:FIELD
173-
{
174-
ERROR = 0.10;
175-
ERROR_MODE = RELMIN;
176-
ERROR_MIN = 0.10;
177-
};
178-
179118
.. _error_modes:
180119

181120
Error modes for summary observations
182121
------------------------------------
183122

184123
The item ERROR_MODE can take three different values: ABS, REL or RELMIN.
185-
The default error mode for the :ref:`HISTORY_OBSERVATION <history_observation>`
186-
keyword is RELMIN, while the default for the :ref:`SUMMARY_OBSERVATION <summary_observation>`
124+
The default error mode for the :ref:`SUMMARY_OBSERVATION <summary_observation>`
187125
keyword is ABS.
188126

189127
The default value for `ERROR_MIN` is 0.1.
@@ -203,14 +141,15 @@ the updating process. Therefore, it is important to have consistency
203141
between setting up the errors and the degree of uncertainty in an
204142
observation.
205143

206-
The default error mode and values can be changed as follows, the examples
207-
show only HISTORY_OBSERVATION, but the configurtion is identical for
208-
SUMMARY_OBSERVATION:
144+
The default error mode and values can be changed as follows:
209145

210146
.. code-block:: none
211147
212-
HISTORY_OBSERVATION GOPR:FIELD
148+
SUMMARY_OBSERVATION GOPR_FIELD_OBS_NAME
213149
{
150+
VALUE = 0.9;
151+
DATE = 2014-09-10;
152+
KEY = GOPR:FIELD;
214153
ERROR = 1000;
215154
ERROR_MODE = ABS;
216155
};
@@ -228,8 +167,11 @@ observation uncertainity:
228167

229168
.. code-block:: none
230169
231-
HISTORY_OBSERVATION GWIR:FIELD
170+
SUMMARY_OBSERVATION GWIR_FIELD_OBS_NAME
232171
{
172+
VALUE = 0.9;
173+
DATE = 2014-09-10;
174+
KEY = GWIR:FIELD;
233175
ERROR = 0.20;
234176
ERROR_MODE = REL;
235177
};
@@ -240,8 +182,11 @@ keyword ERROR_MIN:
240182

241183
.. code-block:: none
242184
243-
HISTORY_OBSERVATION GWIR:FIELD
185+
SUMMARY_OBSERVATION GWIR_FIELD_OBS_NAME
244186
{
187+
VALUE = 0.9;
188+
DATE = 2014-09-10;
189+
KEY = GWIR:FIELD;
245190
ERROR = 0.20;
246191
ERROR_MODE = RELMIN;
247192
ERROR_MIN = 100;
@@ -254,45 +199,6 @@ Note that the configuration parser does not treat carriage return
254199
different from space. Thus, the following statement is equivalent to
255200
the previous:
256201

257-
.. code-block:: none
258-
259-
HISTORY_OBSERVATION GWIR:FIELD { ERROR = 0.20; ERROR_MODE = RELMIN; ERROR_MIN = 100; };
260-
261-
To change the observation error for a HISTORY_OBSERVATION for one or
262-
more segments of the historic period, you can use the SEGMENT
263-
keyword. For example:
264-
265-
.. code-block:: none
266-
267-
HISTORY_OBSERVATION GWIR:FIELD
268-
{
269-
ERROR = 0.20;
270-
ERROR_MODE = RELMIN;
271-
ERROR_MIN = 100;
272-
273-
SEGMENT FIRST_YEAR
274-
{
275-
START = 0;
276-
STOP = 10;
277-
ERROR = 0.50;
278-
ERROR_MODE = REL;
279-
};
280-
281-
SEGMENT SECOND_YEAR
282-
{
283-
START = 11;
284-
STOP = 20;
285-
ERROR = 1000;
286-
ERROR_MODE = ABS;
287-
};
288-
};
289-
290-
The items START and STOP set the start and stop of the segment in
291-
terms of ECLIPSE restart steps. The keywords ERROR, ERROR_MODE and
292-
ERROR_MIN behave like before. If the segments overlap, they are
293-
computed in alphabetical order.
294-
295-
296202
.. _general_observation:
297203

298204
GENERAL_OBSERVATION keyword

0 commit comments

Comments
 (0)