Skip to content

Commit 1bcc83e

Browse files
author
Matt Roeschke
committed
Add scricter check, remove sum benchmark since its unsupported in numba
1 parent 3c49d03 commit 1bcc83e

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

asv_bench/benchmarks/rolling.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,8 @@ class Apply:
3030
["DataFrame", "Series"],
3131
[10, 1000],
3232
["int", "float"],
33-
[sum, np.sum, lambda x: np.sum(x) + 5],
33+
# TODO: numba doesn't support builtin.sum
34+
[np.sum, lambda x: np.sum(x) + 5],
3435
[True, False],
3536
)
3637
param_names = ["contructor", "window", "dtype", "function", "raw"]

pandas/core/window/rolling.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1145,7 +1145,7 @@ def apply(self, func, raw=None, args=(), kwargs={}):
11451145
def make_rolling_apply(func):
11461146
@numba.generated_jit(nopython=True)
11471147
def numba_func(window, *_args):
1148-
if getattr(np, func.__name__, False):
1148+
if getattr(np, func.__name__, False) is func:
11491149

11501150
def impl(window, *_args):
11511151
return func(window, *_args)

0 commit comments

Comments
 (0)