Use the decremental approach in the hypervolume contribution calculation#6264
Merged
y0z merged 3 commits intooptuna:masterfrom Sep 5, 2025
Merged
Use the decremental approach in the hypervolume contribution calculation#6264y0z merged 3 commits intooptuna:masterfrom
y0z merged 3 commits intooptuna:masterfrom
Conversation
Contributor
|
@y0z |
Contributor
nabenabe0928
reviewed
Sep 2, 2025
nabenabe0928
reviewed
Sep 2, 2025
Contributor
nabenabe0928
left a comment
There was a problem hiding this comment.
Mostly LGTM:)
I left a minor comment!
Co-authored-by: Shuhei Watanabe <47781922+nabenabe0928@users.noreply.github.com>
nabenabe0928
reviewed
Sep 2, 2025
Comment on lines
+844
to
+848
| contribs[on_front] = np.prod(ref_point - pareto_sols, axis=-1) | ||
| limited_sols = np.maximum(pareto_sols, pareto_sols[:, np.newaxis]) | ||
| contribs[on_front] -= [ | ||
| compute_hypervolume(limited_sols[i, loo], ref_point) for i, loo in enumerate(loo_mat) | ||
| ] |
Contributor
There was a problem hiding this comment.
Just in case, I confirmed that this part does not fail even if len(pareto_sols) == 1.
The hypervolume contribution in this case must be identical to compute_hypervolume(pareto_sols, ref_point, assume_pareto=True), which we successfully get here.
Note
Since n_below_feasible <= 1 immediately returns weights_below above, pareto_sols will not be empty.
nabenabe0928
approved these changes
Sep 2, 2025
Contributor
nabenabe0928
left a comment
There was a problem hiding this comment.
Thank you for the update, LGTM!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
The contribution calculation in
_calculate_weights_below_for_multi_objectivecan be accelerated by using the difference between own hv and intersection's one.Description of the changes
Using diff in contribution calculation.
Note: contribs[i] = H(S v {i)) - H(S) = H({i}) - H(S ^ {i}).
Benchmark