go(de): declare initialised after pop.Init()
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
leo 2023-01-19 20:30:14 +01:00
parent 8f55d80731
commit 86533bdefe
Signed by: wanderer
SSH Key Fingerprint: SHA256:Dp8+iwKHSlrMEHzE3bJnPng70I7LEsa3IJXRH/U+idQ

View File

@ -101,11 +101,14 @@ func (j *JDE) Init(generations, mutStrategy, adptScheme, np int, f, cr float64,
j.Dimensions = dimensions
j.BenchName = bench
j.ch = ch
j.initialised = true
pop := newPopulation(bench, j.NP)
pop.Init()
j.Population = pop
j.initialised = true
}
// InitAndRun initialises the jDE algorithm, performs sanity checks on the