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

ENH: Add calculation of water zone volumes #925

Merged
merged 1 commit into from
Dec 19, 2024
Merged

Conversation

tnatt
Copy link
Collaborator

@tnatt tnatt commented Dec 16, 2024

No description provided.

@tnatt tnatt marked this pull request as draft December 16, 2024 13:48
@tnatt tnatt force-pushed the water_volumes branch 3 times, most recently from 908fb35 to 8e25e9f Compare December 17, 2024 08:24
@tnatt tnatt self-assigned this Dec 17, 2024
@tnatt tnatt marked this pull request as ready for review December 17, 2024 09:55
@tnatt tnatt force-pushed the water_volumes branch 3 times, most recently from e40f73d to ce54b0c Compare December 19, 2024 08:03
Comment on lines -152 to -154
table_index = [
col for col in _enums.InplaceVolumes.index_columns() if col in table
]
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This was also given as input argument

@tnatt tnatt requested review from mferrera and jcrivenaes December 19, 2024 08:05
Copy link
Collaborator

@mferrera mferrera left a comment

Choose a reason for hiding this comment

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

🚀

Comment on lines +139 to +143
if not total_columns:
raise RuntimeError(
"Found no 'Totals' volumes in the table. Please ensure 'Totals' "
"are reported and rerun the volumetric job before export."
)
Copy link
Collaborator

Choose a reason for hiding this comment

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

This can also be captured more upfront by evaluation the job settings which already are read

(this example from Drogon)

myjob = rmsjobs.Job.get_job(
    owner=["Grid models", "Geogrid", "Grid"],
    type="Volumetrics",
    name="geogrid_volumes",
)

print("USE TOTALS", mydict["Output"][0]["UseTotals"])

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yes I know, did initially check several things on the job settings e.g. required calculations.. but found it difficult to write tests, had to mock so much. I'll keep it here for now and we can move later if we want 👍

Copy link
Collaborator

@jcrivenaes jcrivenaes left a comment

Choose a reason for hiding this comment

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

👍

@tnatt tnatt merged commit a2194ec into equinor:main Dec 19, 2024
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants