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

Fix get_infeasible_cost for objectives that require X #1721

Closed
wants to merge 4 commits into from

Conversation

jduerholt
Copy link
Contributor

Motivation

The method get_infeasible_cost is currently not able to also handle objectives that require also X values, which will be the new default in one of the next releases. This PR fixes it.

Have you read the Contributing Guidelines on pull requests?

Yes.

Test Plan

Unit tests.

@facebook-github-bot facebook-github-bot added the CLA Signed Do not delete this pull request or issue due to inactivity. label Mar 3, 2023
@jduerholt jduerholt changed the title add X to objective evaluation Fix get_infeasible_cost for objectives that require X Mar 3, 2023
@codecov
Copy link

codecov bot commented Mar 3, 2023

Codecov Report

Merging #1721 (463f349) into main (ba90c9b) will not change coverage.
The diff coverage is 100.00%.

❗ Current head 463f349 differs from pull request most recent head a2cf481. Consider uploading reports for the commit a2cf481 to get more accurate results

@@            Coverage Diff            @@
##              main     #1721   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          170       170           
  Lines        14621     14621           
=========================================
  Hits         14621     14621           
Impacted Files Coverage Δ
botorch/acquisition/input_constructors.py 100.00% <ø> (ø)
botorch/acquisition/multi_objective/objective.py 100.00% <ø> (ø)
botorch/acquisition/utils.py 100.00% <100.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@jduerholt
Copy link
Contributor Author

@saitcakmak @Balandat any thoughts on this? ;)

Copy link
Contributor

@Balandat Balandat left a comment

Choose a reason for hiding this comment

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

This makes sense to me - could you add a unit tests that checks the new behavior of get_infeasible_cost if the objective indeed does depend on X? Thanks!

Co-authored-by: Max Balandat <Balandat@users.noreply.github.com>
@jduerholt
Copy link
Contributor Author

This makes sense to me - could you add a unit tests that checks the new behavior of get_infeasible_cost if the objective indeed does depend on X? Thanks!

Yes, I will add something!

@jduerholt
Copy link
Contributor Author

I just added a test, hope it is fine now ;)

@jduerholt jduerholt requested a review from Balandat March 12, 2023 18:44
@facebook-github-bot
Copy link
Contributor

@Balandat has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

Copy link
Contributor

@Balandat Balandat left a comment

Choose a reason for hiding this comment

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

great, lgtm! Thanks for the fix.

@facebook-github-bot
Copy link
Contributor

@Balandat merged this pull request in 4a76513.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Do not delete this pull request or issue due to inactivity. Merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants