File tree Expand file tree Collapse file tree 2 files changed +0
-17
lines changed
pytensor/link/numba/dispatch Expand file tree Collapse file tree 2 files changed +0
-17
lines changed Original file line number Diff line number Diff line change 4242from pytensor .tensor .type_other import MakeSlice , NoneConst
4343
4444
45- def global_numba_func (func ):
46- """Use to return global numba functions in numba_funcify_*.
47-
48- This allows tests to remove the compilation using mock.
49- """
50- return func
51-
52-
5345def numba_njit (* args , fastmath = None , ** kwargs ):
5446 kwargs .setdefault ("cache" , config .numba__cache )
5547 kwargs .setdefault ("no_cpython_wrapper" , True )
Original file line number Diff line number Diff line change @@ -150,17 +150,8 @@ def njit_noop(*args, **kwargs):
150150 else :
151151 return lambda x : x
152152
153- def py_global_numba_func (func ):
154- if hasattr (func , "py_func" ):
155- return func .py_func
156- return func
157-
158153 mocks = [
159154 mock .patch ("numba.njit" , njit_noop ),
160- mock .patch (
161- "pytensor.link.numba.dispatch.basic.global_numba_func" ,
162- py_global_numba_func ,
163- ),
164155 mock .patch (
165156 "pytensor.link.numba.dispatch.basic.tuple_setitem" , py_tuple_setitem
166157 ),
You can’t perform that action at this time.
0 commit comments