Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move EclSum support from serializers to transformations #2613

Merged
merged 1 commit into from
Jan 5, 2022

Conversation

berland
Copy link
Contributor

@berland berland commented Dec 17, 2021

Issue
Resolves #2121

Approach
Short description of the approach

Pre review checklist

  • Added appropriate labels

@berland berland marked this pull request as draft December 17, 2021 12:39
@codecov-commenter
Copy link

codecov-commenter commented Dec 17, 2021

Codecov Report

Merging #2613 (94d7347) into main (17af879) will decrease coverage by 0.00%.
The diff coverage is 100.00%.

❗ Current head 94d7347 differs from pull request most recent head 73d6cf2. Consider uploading reports for the commit 73d6cf2 to get more accurate results
Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2613      +/-   ##
==========================================
- Coverage   64.82%   64.82%   -0.01%     
==========================================
  Files         648      648              
  Lines       54188    54188              
  Branches     4517     4517              
==========================================
- Hits        35128    35127       -1     
- Misses      17653    17655       +2     
+ Partials     1407     1406       -1     
Impacted Files Coverage Δ
ert3/algorithms/_sensitivity.py 90.29% <100.00%> (ø)
ert3/config/_ensemble_config.py 96.82% <100.00%> (ø)
ert_gui/simulation/run_dialog.py 75.70% <0.00%> (-0.71%) ⬇️
libres/lib/enkf/block_fs_driver.cpp 81.92% <0.00%> (+0.56%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 17af879...73d6cf2. Read the comment docs.

@sondreso sondreso changed the title Smry trans Summary transformation Dec 17, 2021
@berland berland added the ert3 label Dec 21, 2021
@berland berland force-pushed the smry_trans branch 2 times, most recently from b8ec2dd to a040e4c Compare December 21, 2021 13:27
@berland berland changed the title Summary transformation Move EclSum support from serializers to transformations Dec 22, 2021
ert3/evaluator/_builder.py Outdated Show resolved Hide resolved
@berland berland marked this pull request as ready for review January 4, 2022 08:23
@xjules
Copy link
Contributor

xjules commented Jan 4, 2022

Another mypy issues:

ert3/config/_ensemble_config.py:48: error: unused "type: ignore" comment
ert3/algorithms/_sensitivity.py:109: error: unused "type: ignore" comment

@@ -106,16 +102,13 @@ def add_step_outputs(
step: StepBuilder,
) -> None:
for record_name, output in step_config.output.items():
transformation = _get_output_recordtransformation(output)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This might not be part of this PR, but shouldn't we also create LinkedOutput class then?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The outputs don't have the same kind of configurability as the inputs, so it isn't currently needed. The reason linked inputs exist, is due to the separate stages and ensemble configuration scheme, where the same input (record) can serve as inputs for multiple ensembles. This doesn't currently apply for outputs.

@xjules
Copy link
Contributor

xjules commented Jan 4, 2022

Another mypy issues:

ert3/config/_ensemble_config.py:48: error: unused "type: ignore" comment
ert3/algorithms/_sensitivity.py:109: error: unused "type: ignore" comment

It's been fixed in 94d7347 it seems, so just rebase

Copy link
Collaborator

@sondreso sondreso left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks very good! Only had one small comment.

ert/data/record/_transformation.py Outdated Show resolved Hide resolved
Eclipse binary output can now be "transformed" from
its binary state into a NumericalRecordTree with nodes being
the summary vector names. Summary vectors are extracted according
to an explicit list.
@jondequinor
Copy link
Contributor

Can I still load summary data from the command line after this pr?

@xjules
Copy link
Contributor

xjules commented Jan 5, 2022

Can I still load summary data from the command line after this pr?

Very good point (although not sure if we were loading the summary data from command line before 🤔 )!
Regardless, I think we should extend the command line interface for summary data too (at least in another PR / creating an issue for it).
See is-directory for example:

"--is-directory",

@jondequinor
Copy link
Contributor

Very good point (although not sure if we were loading the summary data from command line before 🤔 )!

The command line dispatched stuff to the serialiser, so that should've worked before this pr. didn't test it though.

@xjules
Copy link
Contributor

xjules commented Jan 5, 2022

Very good point (although not sure if we were loading the summary data from command line before thinking )!

The command line dispatched stuff to the serialiser, so that should've worked before this pr. didn't test it though.

Very good point (although not sure if we were loading the summary data from command line before thinking )!

The command line dispatched stuff to the serialiser, so that should've worked before this pr. didn't test it though.

According to the previous experience, this feature didn't work (ie. extracting particular keys). Moreover, decided not to have a command line option for summary data (at least for now).

Copy link
Contributor

@xjules xjules left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work and LGTM now! 🚀

@berland berland merged commit 19068cc into equinor:main Jan 5, 2022
@berland berland deleted the smry_trans branch January 7, 2022 14:58
@berland berland mentioned this pull request Jan 11, 2022
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
5 participants