Repository navigation
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #507 +/- ##
=======================================
Coverage 54.22% 54.22%
=======================================
Files 1 1
Lines 225 225
=======================================
Hits 122 122
Misses 103 103 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
marcomangano
left a comment
Collaborator
There was a problem hiding this comment.
Looks good to me, thanks for the clear documentation and the added tests! I only have a question about them, see below.
| def test_egor_user_termination(self): | ||
| # Termination after the initial DOE: handled by Egor, the best point is returned | ||
| sol = self.run_terminated_xsinx(lambda: 2) | ||
| self.assertTrue(np.isfinite(sol.fStar)) |
Collaborator
There was a problem hiding this comment.
Why are this and the following test just checking if sol.fstar is finite? Wouldn't it be stronger to pass the known solution value? I might be missing some details about how the DOE works here.
Contributor
Author
There was a problem hiding this comment.
You're right! Now I check that fStar is the minimum of the objective values evaluated
marcomangano
approved these changes
Nov 20, 2026
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.
Purpose
Fixes two Egor wrapper defects found while adding Egor to OpenMDAO's
pyOptSparseDriver(OpenMDAO/OpenMDAO#3854). With these fixes, OpenMDAO needs no Egor-specific workaround.np.isfinitecheck. They now raise aValueErrorlisting the unbounded variables.fail = 2): Egor treated it as a failed point and went on. It now stops with inform 3, as SNOPT, IPOPT and Uno do. During the initial DOE, the initial point is returned withfStar = NaN.gp_configdefaults, and the list of optimizers supportingfail = 2.egobox>=1.1.0, needed for interruption during the initial DOE. Otherwise the wrapper stays compatible with egobox 1.0.Expected time until merged
Not urgent, about a week.
Type of change
Testing
New tests in
tests/test_egor.pycover unbounded design variables, andfail = 2and Ctrl+C during and after the initial DOE. Egor is added totest_user_termination.py::test_obj.Checklist
ruff checkandruff formatto make sure the Python code adheres to PEP-8 and is consistently formattedfprettifyor C/C++ code withclang-formatas applicable