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

Enable multi-objective optimisation #61

Merged
merged 1 commit into from
Jul 12, 2024

Conversation

benedikt-voelkel
Copy link
Collaborator

Multiple scalars can now be returned by an objective function, while the default is only one scalar.

In case of multiple objectives (multiple numbers), the objective function must be decorated with the respective directions:

@directions(['minimize', 'maximize'])
def my_objective(...):

do your calculations

return value_to_minimize, value_to_maximize

If only one number is returned, the decorator can be omitted if that number should be minimized.

If maximization is desired,n single-objective optimisation, the decorator should be used with
@directions(['maximize'])
def my_objective(...):

do your calculations

return value_to_maximize

All plotting functions of the Inspector now have a keyword argument objective_number
to indicate for which of those objective the respctive plot should be created.

Multiple scalars can now be returned by an objective function,
while the default is only one scalar.

In case of multiple objectives (multiple numbers), the
objective function must be decorated with the respective directions:

@directions(['minimize', 'maximize'])
def my_objective(...):
  # do your calculations
  return value_to_minimize, value_to_maximize

If only one number is returned, the decorator can be omitted if that number
should be minimized.

If maximization is desired,n single-objective optimisation, the decorator
should be used with
@directions(['maximize'])
def my_objective(...):
  # do your calculations
  return value_to_maximize

All plotting functions of the Inspector now have a keyword argument
objective_number
to indicate for which of those objective the respctive plot should be created.
@benedikt-voelkel
Copy link
Collaborator Author

@mconcas Tadaaaa!

@mconcas mconcas merged commit 4ea72ea into AliceO2Group:master Jul 12, 2024
6 checks passed
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