Remove init location from FunctionConverge
MODIFY
optimize/functionconvergence.go
optimize/functionconvergence.go
@@ -18,7 +18,7 @@ type FunctionConverge struct {
iter int
}
-func (fc *FunctionConverge) Init(f float64) {
+func (fc *FunctionConverge) Init() {
fc.first = true
fc.best = 0
fc.iter = 0

MODIFY
optimize/global.go
optimize/global.go
@@ -127,7 +127,7 @@ func Global(p Problem, dim int, settings *Settings, method GlobalMethod) (*Resul
optLoc.F = math.Inf(1)
if settings.FunctionConverge != nil {
- settings.FunctionConverge.Init(optLoc.F)
+ settings.FunctionConverge.Init()
}
stats.Runtime = time.Since(startTime)

Remove init location from FunctionConverge (#489)