Closed dex3r closed 1 year ago
Unfortunately, I couldn't understand what is the problem you are trying to point out in this issue, because the idea to pass MinSize to the implementation of the ISelection interface is to guarantee that the minimum size of the population will be respected, in some cases the selection could generate more chromosomes than min size, but never less than it.
Can you provide a unit test exposing the problem that you mentioned?
Closed due to inactivity. Feel free to reopen it if needed.
Describe the bug It seems that Selection has no effect on population?
To Reproduce
Replace
GeneticAlghoritm.SelectParents
with this code:if
statement is never executed.Expected behavior Selection should select chromosomes according to its algorithm. Instead, the population count is always equal to
MinSize
when enteringSelectParents
method, rendering any Selection method useless.Version: Commit hash: a648e253d977ecd7afb26824141281fb9ec74ae3