Skip to content

Commit

Permalink
FIX: Numba
Browse files Browse the repository at this point in the history
  • Loading branch information
larsoner committed Sep 23, 2023
1 parent 776f129 commit 3997cf8
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions mne/fixes.py
Original file line number Diff line number Diff line change
Expand Up @@ -807,21 +807,6 @@ def bincount(x, weights, minlength): # noqa: D103
out[idx] += w
return out

# fix because Numba does not support axis kwarg for mean
@jit()
def _np_apply_along_axis(func1d, axis, arr):
assert arr.ndim == 2
assert axis in [0, 1]
if axis == 0:
result = np.empty(arr.shape[1])
for i in range(len(result)):
result[i] = func1d(arr[:, i])
else:
result = np.empty(arr.shape[0])
for i in range(len(result)):
result[i] = func1d(arr[i, :])
return result


###############################################################################
# Matplotlib
Expand Down

0 comments on commit 3997cf8

Please sign in to comment.