stats = tools.Statistics(key=lambda ind: ind.fitness.values) stats.register("avg", numpy.mean) stats.register("max", numpy.max) stats.register("min", numpy.min)
gen,max,avg,min0,6755.0,1509.2321111111107,-0.80000000000000016
...
creator.create("FitnessMin", base.Fitness, weights=(-1.0, -1.5))
--
You received this message because you are subscribed to the Google Groups "deap-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to deap-users+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Moreover, I have a second question. I defined my multi-objective evaluation function like thisbecause I want to give an higher "priority" to the second objective, because it is more important for me. Did I do it right? Or should the weight be smaller than the first one?creator.create("FitnessMin", base.Fitness, weights=(-1.0, -1.5))
With NSGA-II the weights only influence the crowding distance everything else is made according to pareto dominance. Thus, you should see only little differences between different weightings. The weights are usually used to "normalise" two objectives that are on different scale.
Cheers,
François-Michel
I really don't know, it depends mostly on your problem. I suggest you try both!