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

Improve trust region sampling in tranquilo #388

Merged
merged 21 commits into from
Nov 6, 2022
Merged

Improve trust region sampling in tranquilo #388

merged 21 commits into from
Nov 6, 2022

Conversation

timmens
Copy link
Member

@timmens timmens commented Oct 11, 2022

In this PR we want to improve the trust region sampling of Tranquilo. In particular, we implement

Sphere sampling

  • Naive (random points on the sphere)
  • Optimal (points on the sphere placed to maximize the minimum distance between two points)

Cube sampling

  • Naive (random points on the cube)
  • Optimal (points on the sphere placed to maximize the minimum distance between two points)

If binding bounds are present we map the shape (sphere or cube) into the feasible trustregion, which is defined as the intersection of the bounds and the trustregion.

@codecov
Copy link

codecov bot commented Oct 11, 2022

Codecov Report

Merging #388 (1b5c6a6) into main (e0b5b6c) will increase coverage by 0.05%.
The diff coverage is 96.98%.

@@            Coverage Diff             @@
##             main     #388      +/-   ##
==========================================
+ Coverage   92.73%   92.78%   +0.05%     
==========================================
  Files         209      209              
  Lines       16484    16628     +144     
==========================================
+ Hits        15286    15428     +142     
- Misses       1198     1200       +2     
Impacted Files Coverage Δ
tests/optimization/tranquilo/test_filter_points.py 100.00% <ø> (ø)
.../estimagic/optimization/tranquilo/sample_points.py 91.05% <93.58%> (+1.77%) ⬆️
src/estimagic/optimization/tranquilo/options.py 100.00% <100.00%> (ø)
src/estimagic/optimization/tranquilo/tranquilo.py 96.04% <100.00%> (+0.18%) ⬆️
...imagic/optimization/tranquilo/tranquilo_history.py 75.53% <100.00%> (+0.53%) ⬆️
tests/optimization/tranquilo/test_sample_points.py 100.00% <100.00%> (ø)
...magic/optimization/subsolvers/_trsbox_quadratic.py 92.24% <0.00%> (+1.22%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@timmens timmens requested a review from janosg October 23, 2022 11:55
@timmens timmens requested a review from janosg November 2, 2022 09:00
Copy link
Member

@janosg janosg left a comment

Choose a reason for hiding this comment

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

Very nice!

@janosg janosg merged commit a7c0232 into main Nov 6, 2022
@janosg janosg deleted the sampling branch November 6, 2022 13:04
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.

2 participants