-
Notifications
You must be signed in to change notification settings - Fork 123
Vectorize parameter sampling #12648
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
base: main
Are you sure you want to change the base?
Vectorize parameter sampling #12648
Conversation
❌ 1 Tests Failed:
View the full list of 1 ❄️ flaky test(s)
To view more test analytics, go to the Test Analytics Dashboard |
CodSpeed Performance ReportMerging this PR will not alter performanceComparing Summary
|
achaikou
left a comment
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 am sorry to crash the party uninvited, but I was out of stuff to do 😊
I am also missing some context in the commit description about the reason for the change (is there some problem to be solved or would code just look nicer?), so I have to guess 😄
achaikou
left a comment
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.
Am I right to assume that all those commits would be squashed?
I am just more accustomed to the fixup commit style 🙂
Btw, I am happy with the changes, but I don't feel like an ert-adult yet to click the "Approve" button for this PR 😄
src/ert/config/parameter_config.py
Outdated
| - num_realizations (int): Total number of realizations to generate the | ||
| reproducible sampling. |
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.
Got somewhat confused by the wording (thinking it was "number of realizations that would be generated").
Taking words from your other comment, maybe something like
Total number of realizations. Assures stable sampling for a given global_seed regardless of currently active realizations.
?
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.
Thanks, I have tried to make it more clear :) Also, all the commits will be squashed yes!
Vectorize the sampling rather than drawing one value at a time. This cosmetic change makes the code cleaner and easier to understand. In our view, drawing all samples for a parameter simultaneously is more natural and better aligned with standard sampling APIs (e.g., scipy).
git rebase -i main --exec 'just rapid-tests')When applicable