diff --git a/pymoo/algorithms/moo/spea2.py b/pymoo/algorithms/moo/spea2.py index 71c86436..946adf82 100644 --- a/pymoo/algorithms/moo/spea2.py +++ b/pymoo/algorithms/moo/spea2.py @@ -39,7 +39,7 @@ def _do(self, problem, pop, *args, n_survive=None, **kwargs): M = Dominator().calc_domination_matrix(F) # the number of solutions each individual dominates - S = (M == 1).sum(axis=0) + S = (M == 1).sum(axis=1) # the raw fitness of each solution - strength of its dominators R = ((M == -1) * S).sum(axis=1)