This repository was archived by the owner on Apr 28, 2023. It is now read-only.
Commit 4fc3ab9
[genetic search] Scale fitness before selection
Using an unscaled fitness value for selection is problematic:
-Outstanding individuals take over very quickly, this leads to
premature convergence.
-When fitness values are close together, very litle selection
pressure is applied and selection is almost uniformly random.
Having slightly better fitness does not improve an individual's
survival chances.
-Transposing the fitness function (e.g. adding a constant value)
changes the selection probabilities even though the location of the
optimum (and the "shape" of the fitness) remain unchanged.
Scaling the fitness function helps ameliorate those issues.
Sigma scaling is used:
fitness' = max(fitness - (mean_fitness - 2 * std_fitness), 0)1 parent 02b7b05 commit 4fc3ab9
1 file changed
+30
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
| 20 | + | |
19 | 21 | | |
20 | 22 | | |
21 | 23 | | |
| |||
72 | 74 | | |
73 | 75 | | |
74 | 76 | | |
75 | | - | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
76 | 81 | | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
77 | 103 | | |
| 104 | + | |
| 105 | + | |
78 | 106 | | |
79 | 107 | | |
80 | 108 | | |
| |||
90 | 118 | | |
91 | 119 | | |
92 | 120 | | |
| 121 | + | |
93 | 122 | | |
94 | 123 | | |
95 | 124 | | |
| |||
0 commit comments