Distance-based localiztion test script for testing full update workflow using ERT storage with ensemble experiments - #230
Distance-based localiztion test script for testing full update workflow using ERT storage with ensemble experiments#230oddvarlia wants to merge 15 commits into
Conversation
| groups = list(param_config_all.keys()) | ||
| realizations = ensemble.get_realization_list_with_responses() | ||
| group_number = 0 | ||
| for group_name in groups: |
There was a problem hiding this comment.
You can use enumerate to avoid having to increment group_number manually.
for group_number, group_name in enumerate(groups)
| smoother = DistanceESMDA( | ||
| covariance=C_D, observations=observations, alpha=alpha, seed=seed | ||
| ) | ||
| smoother.prepare_assimilation(Y, truncation=0.99) |
There was a problem hiding this comment.
I think we can as part of the assimilate_batch function and only do the actual calculations if self.X3 and self.D` are not already set.
| # Turn on/off export of field parameters into 3D parameter files in ROFF format to be read by RMS. | ||
| WRITE_STATS_PARAMS = True | ||
|
|
||
| # Common definition of ERTBOX for all zones in Drogon |
There was a problem hiding this comment.
Does the grid file specified using the GRID keyword in the Drogon project contain all this information?
| OBS_FILE_PATH = ( | ||
| "/project/fmu/users/olia/drogon_20250623_11-50/resmod/ff/25.0.0/rms/model/" | ||
| ) | ||
| OBS_FILE = "summary_obs_with_localization_attributes.csv" |
There was a problem hiding this comment.
Can you push this file to the repo as well or is it perhaps too big?
| OBS_SUMMARY_WITH_LOCAL_ATTRIBUTES_FILE = OBS_FILE_PATH + OBS_FILE | ||
|
|
||
| # Hard-coded a classification of parameter groups into scalars, 2D or 3D field parameters | ||
| # NOTE: This should be available from ERT storage (ERT knows about the source the keyword FIELD, SURFACE GEN_KW) |
There was a problem hiding this comment.
Here's one way to get the parameter type:
with open_storage(storage_path, "r") as storage:
experiment = storage.get_experiment_by_name(experiment_name)
print(experiment.parameter_configuration["COND"].type)
# >> field
print(experiment.parameter_configuration["INIT_TEMP_SCALE"].type)
# >> gen_kw| # (e.g for permeabilit or porosity) could be <zone_name>_<facies>_<petro_name> | ||
| # for petrophysical fields to be updated simultaneously with facies update from APS. | ||
| # For reservoir zones without facies modelling, the convention could be <zone_name>_<petro_name> | ||
| # NOTE: An additional parameter in FIELD keyword with zone name can solve the problem if naming convention |
There was a problem hiding this comment.
An issue has been created on this that needs more information:
00e0f0e to
974fcfb
Compare
|
I suggest we generate .csv files that are comma delimited and not delimited by space. This can avoid potential bugs if for example a zone name has a space in its name. |
a5846f6 to
0b1f9a9
Compare
7505b9c to
14a73ba
Compare
6992e30 to
c7e0d02
Compare
41ecce3 to
3dc8862
Compare
379e45b to
49af424
Compare
|
The class DistanceESMDA is now merged into main. See merged PR 240. The test script with additional help scripts for RMS and yml files for drogon case is not merged. |
49af424 to
82a16a6
Compare
8baf006 to
780f49a
Compare
577d167 to
b5f3fae
Compare
b5f3fae to
ba89bfd
Compare
…ning on a case from ERT storage Added description of implementation steps Update create_obs_with_localisation_attributes update distance_based_on_real_case.py Working version with summary data Added seismic obs and RFT obs Attempt to save update to ERT storage Added tracer obs Added tracer obs file Added ESMDA update to scalars Modified the path to where on scratch to find the ensemble Ensure that updated ensemble in storage has iteration greater than 0 Added new scaling function Changed seismic_range Update scalar parameters Updated document lines Updated test_distance_based.ipynb to initialize ESMDA before each update Update code and use ertbox parameters from storage Update input to handle seismic and rft obs per zone Added adaptive localisation for scalara parameters Added functionality to simulate spatially correlated seismic observation errors Added option to specify D matrix as input to ESMDA and DistanceESMDA update distance_based_on_real_case.py to work with new version of storage Update experimental.py and test_experimental.py to be equal to main
ba89bfd to
ee10d05
Compare
|
Closing as this was not meant to be merged but was pushed for discussions. |
The script is initially using Drogon case from this summer.
The distance-based localization depends on having position for observations (well prod observations and seismic points for 4D)
This is currently not available in ERT and storage directories created by ERT so the information must be taken from the FMU setup for seismic observations and the RMS forward model.
A script to extract position data from wells using RMS project is included
The plan is to get position data for the seismic observations as well by loading files with seismic data points including position from ERT project.
Main goal of this branch is to test and evaluate performance of distance-based localization before the method is implemented in ERT code.
This branch is built on the branch Distance-based localization per 15.08.2025