From 286c38bd1ae34870c40986e8ddebfd65d6e5049e Mon Sep 17 00:00:00 2001 From: Aleksandr Nogikh Date: Thu, 13 Jun 2024 20:30:13 +0200 Subject: pkg/stats: split out pkg/stats/sample This will reduce the number of dependencies needed for the main syzkaller tools. --- pkg/stats/pvalue.go | 20 -------------------- 1 file changed, 20 deletions(-) delete mode 100644 pkg/stats/pvalue.go (limited to 'pkg/stats/pvalue.go') diff --git a/pkg/stats/pvalue.go b/pkg/stats/pvalue.go deleted file mode 100644 index 9f413f5aa..000000000 --- a/pkg/stats/pvalue.go +++ /dev/null @@ -1,20 +0,0 @@ -// Copyright 2021 syzkaller project authors. All rights reserved. -// Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file. - -package stats - -// TODO: I didn't find the substitution as of Feb 2023. Let's keep it as is while it works. -import "golang.org/x/perf/benchstat" // nolint:all - -// Mann-Whitney U test. -func UTest(old, new *Sample) (pval float64, err error) { - // Unfortunately we cannot just invoke MannWhitneyUTest from x/perf/benchstat/internal/stats, - // so we first wrap the data in Metrics. - mOld := benchstat.Metrics{ - RValues: old.Xs, - } - mNew := benchstat.Metrics{ - RValues: new.Xs, - } - return benchstat.UTest(&mOld, &mNew) -} -- cgit mrf-deployment