evox.metrics.gd
#
Module Contents#
Functions#
Calculate the Generational Distance (GD) metric between a set of solutions and the Pareto front. |
API#
- evox.metrics.gd.gd(objs: torch.Tensor, pf: torch.Tensor)[source]#
Calculate the Generational Distance (GD) metric between a set of solutions and the Pareto front.
- Parameters:
objs – A tensor of shape (n, m), where n is the number of solutions and m is the number of objectives. Represents the set of solutions to be evaluated.
pf – A tensor of shape (k, m), where k is the number of points on the Pareto front and m is the number of objectives. Represents the true Pareto front.
- Returns:
The GD score, a scalar representing the average distance of the solutions to the Pareto front.
- Note:
The GD score is lower when the approximation is closer to the Pareto front.