Conversation
… used by the Optimizer to manage UserFn/nlopt::ObjFn duality
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.
This pull request introduces several important refactorings and improvements to the EGO optimizer codebase, focusing on unifying and clarifying function trait usage, improving error handling, and enhancing test coverage for user function failures. The changes also adjust clustering defaults and improve logging for failed objective evaluations.
Refactoring and trait unification
GroupFuncwith a new, more generalObjFntrait throughout the EGO optimizer, including in theEgorFactory,Egorstructs, and related function signatures. This unifies the way objective functions are represented and simplifies trait bounds. [1] [2] [3] [4] [5] [6]OptFntrait as a wrapper around eitherUserFnorObjFn(depending on the presence of thenloptfeature), and updated theOptimizerstruct and its methods to useOptFnfor both the objective and constraints. [1] [2] [3] [4] [5]Error handling and logging improvements
EgoErrorto a more descriptiveUserFnError, clarifying error sources.Test improvements
test_sphere_periodic_failures) that simulates periodic failures in the user-defined objective function, ensuring that the optimizer correctly handles and records failed evaluations.Documentation and naming consistency
ProblemFuncinstead of the oldObjFuncfor clarity and consistency. [1] [2] [3] [4]DomainConstraintstoConstraintsfor improved clarity and consistency. [1] [2] [3] [4] [5] [6]Clustering and configuration
Enabledvariant in theDataClusteringenum. [1] [2]