mo.pareto.is_pareto_efficient
mo.pareto.is_pareto_efficient(costs, minimize=True)Find the Pareto-efficient points from a set of points.
A point is Pareto-efficient if no other point exists that is better in all objectives. This function assumes that lower values are preferred for each objective when minimize=True, and higher values are preferred when minimize=False.
Parameters
| Name | Type | Description | Default |
|---|---|---|---|
| costs | np.ndarray | An (N,M) array-like object of points, where N is the number of points and M is the number of objectives. | required |
| minimize | bool | If True, the function finds Pareto-efficient points assuming lower values are better. If False, it assumes higher values are better. Defaults to True. | True |
Returns
| Name | Type | Description |
|---|---|---|
| np.ndarray | np.ndarray: A boolean mask of length N, where True indicates that the corresponding point is Pareto-efficient. |
Examples:
>>> import numpy as np
>>> from spotoptim.mo.pareto import is_pareto_efficient
>>> points = np.array([[1, 2], [2, 1], [1.5, 1.5], [3, 3]])
>>> pareto_mask = is_pareto_efficient(points, minimize=True)
>>> print(pareto_mask)
[ True True True False]