-
Notifications
You must be signed in to change notification settings - Fork 110
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
Validate DESIGN_MATRIX
when running DESIGN2PARAMS
#10316
Validate DESIGN_MATRIX
when running DESIGN2PARAMS
#10316
Conversation
CodSpeed Performance ReportMerging #10316 will not alter performanceComparing Summary
|
src/ert/config/ert_config.py
Outdated
if ert_design_matrix_error := ert_design_matrix._validate_design_matrix( | ||
ert_design_matrix | ||
): | ||
raise Exception("\n".join(ert_design_matrix_error)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why the full Exception
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will change it to ConfigurationError 👌
Could you write a test for this validation? It can be even part of test_design_matrix like test_design2params validation. |
I am not sure if we will have the DESIGN2PARAMS forward model installed when running our test suite.. |
0d364f6
to
6b4c554
Compare
f"""\ | ||
NUM_REALIZATIONS 1 | ||
FORWARD_MODEL DESIGN2PARAMS(<xls_filename>={design_matrix_file}, <designsheet>=DesignSheet01,<defaultssheet>=DefaultSheet) | ||
FORWARD_MODEL DESIGN2PARAMS(<xls_filename>={design_matrix_file}, <designsheet>=DesignSheet02,<defaultssheet>=DefaultSheet) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where do you define DesignSheet02? I see now. But tbh I don't like this create_design_matrix "improvement" as it suggests that there might be more designsheets 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why wouldn't we accept multiple designsheets? I assumed that was something we supported because we had the 01 suffix in DesignSheet01.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You were right, we cannot have designsheet01 and designsheet02 in the same xlsx file..
6b4c554
to
b3b8216
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it looks good 🚀
b3b8216
to
f23ce36
Compare
This commit makes us run validation for DESIGN_MATRIX when parsing configs using DESIGN2PARAMS, and log a warning if it would have failed.
f23ce36
to
8ffd82d
Compare
Issue
Resolves #10271
Approach
This commit makes us run validation for DESIGN_MATRIX when parsing configs using DESIGN2PARAMS, and log a warning if it would have failed.
(Screenshot of new behavior in GUI if applicable)
git rebase -i main --exec 'just rapid-tests'
)When applicable