From c459e9549fca169119feb6dfc39039ce7d8c600a Mon Sep 17 00:00:00 2001 From: Ralf Gommers Date: Sun, 27 Aug 2023 22:19:05 +0200 Subject: [PATCH] BENCH: fix issue with `UnaryFP` benchmark, and reduce parametrization --- benchmarks/benchmarks/bench_ufunc_strides.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/benchmarks/benchmarks/bench_ufunc_strides.py b/benchmarks/benchmarks/bench_ufunc_strides.py index 898cc0818ac1..9d6da3150aeb 100644 --- a/benchmarks/benchmarks/bench_ufunc_strides.py +++ b/benchmarks/benchmarks/bench_ufunc_strides.py @@ -100,7 +100,11 @@ def time_unary(self, ufunc, stride_in, stride_out, dtype): ufunc(*self.ufunc_args) class UnaryFP(_AbstractUnary): - params = [UFUNCS_UNARY, [1, 2, 4], [1, 2, 4], ['e', 'f', 'd']] + params = [[uf for uf in UFUNCS_UNARY if uf != np.invert], + [1, 4], + [1, 2], + ['e', 'f', 'd'] + ] def setup(self, ufunc, stride_in, stride_out, dtype): _AbstractUnary.setup(self, ufunc, stride_in, stride_out, dtype) @@ -115,7 +119,7 @@ class UnaryFPSpecial(UnaryFP): class BinaryFP(_AbstractBinary): params = [ [np.maximum, np.minimum, np.fmax, np.fmin, np.ldexp], - [1, 2, 4], [1, 2, 4], [1, 2, 4], ['f', 'd'] + [1, 2], [1, 4], [1, 2, 4], ['f', 'd'] ] class BinaryFPSpecial(BinaryFP):