go(algo): use Dimensions slice from the bench pkg
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
surtur 2022-07-17 11:57:40 +02:00
parent 7742642e14
commit 6db4b60875
Signed by: wanderer
GPG Key ID: 19CE1EC1D9E0486D
2 changed files with 3 additions and 3 deletions

View File

@ -30,7 +30,7 @@ funcCount := len(bench.Functions)
for i := range algoStats {
// ng y'all.
go RandomSearchNG(10000, 30, []int{5, 10, 20}, bench.FuncNames[i], ch)
go RandomSearchNG(10000, 30, bench.Dimensions, bench.FuncNames[i], ch)
}
// get results.
@ -77,7 +77,7 @@ funcCount := len(bench.Functions)
ch := make(chan []stats.Stats, funcCount)
for i := range algoStats {
go HillClimb(10000, 30, []int{5, 10, 20}, bench.FuncNames[i], ch)
go HillClimb(10000, 30, bench.Dimensions, bench.FuncNames[i], ch)
}
// get results.

View File

@ -21,7 +21,7 @@ type funcParams struct {
var (
// Dimensions to compute for (spatial complexity..?).
Dimensions = []uint{5, 10, 20}
Dimensions = []int{5, 10, 20}
// SchwefelParams is a struct holding the min, max allowed value of inputs
// passed to the Schwefel function.