diff --git a/tools/benchmark/stats.go b/tools/benchmark/stats.go index c659fbf..b676cd7 100644 --- a/tools/benchmark/stats.go +++ b/tools/benchmark/stats.go @@ -34,7 +34,7 @@ func NewStats(name string, duration time.Duration, frames int, frameSeconds []in if len(fps) > 0 { stats.MinFPS = slices.Min(fps) stats.MaxFPS = slices.Max(fps) - stats.StdDevFPS = standardDeviation(fps) + stats.StdevFPS = standardDeviation(fps) } return stats @@ -42,11 +42,11 @@ func NewStats(name string, duration time.Duration, frames int, frameSeconds []in // Stats stores data about the performance of a benchmark run type Stats struct { - Name string `json:"name"` - AvgFPS float64 `json:"avgFPS"` - MinFPS float64 `json:"minFPS"` - MaxFPS float64 `json:"maxFPS"` - StdDevFPS float64 `json:"stddevFPS"` + Name string `json:"name"` + AvgFPS float64 `json:"avgFPS"` + MinFPS float64 `json:"minFPS"` + MaxFPS float64 `json:"maxFPS"` + StdevFPS float64 `json:"stdevFPS"` Frames int `json:"frames"` Duration time.Duration `json:"duration"` @@ -61,7 +61,7 @@ func (s *Stats) Print() { fmt.Fprintf(w, " Avg:\t%v\n", roundFloat(s.AvgFPS, 2)) fmt.Fprintf(w, " Min:\t%v\n", roundFloat(s.MinFPS, 2)) fmt.Fprintf(w, " Max:\t%v\n", roundFloat(s.MaxFPS, 2)) - fmt.Fprintf(w, " Stdev:\t%v\n", roundFloat(s.StdDevFPS, 2)) + fmt.Fprintf(w, " Stdev:\t%v\n", roundFloat(s.StdevFPS, 2)) w.Flush() }