Generational Distance

Generational Distance #

File position: /EMOC/src/metric/gd.h and /EMOC/src/metric/gd.cpp

double CalculateGD(Individual** pop, int pop_num, int obj_num, double** pf_data, int pf_size)

Calculate the generational distance value of current population pop based on the pareto front data pf_data.

Parameter:
pop: Individual**, default=None
    The population which need to be initialized. It's an array of Individual* where each Individual* is a pointer to a individual in the population.

pop_num: int, default=None
    The size of the given population.

obj_num: int, default=None
    The number of objectives.

pf_data: double**, default=None
    The pareto front data. It's a 2D array of double (pf_size X obj_num).

pf_size: int, default=None
    The size of the pareto front pf_data.
Returns:
gd_value: double
    Generational distance of current population pop.