Skip to content
This repository has been archived by the owner on Sep 25, 2023. It is now read-only.

Unpin numpy in cusignal #510

Merged
merged 2 commits into from
Oct 18, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Update resample.py
  • Loading branch information
galipremsagar authored Oct 18, 2022
commit 0172d2b6702dc01cc5e5d62fb6e15c3bdcd94cbd
4 changes: 2 additions & 2 deletions python/cusignal/filtering/resample.py
Original file line number Diff line number Diff line change
Expand Up @@ -264,9 +264,9 @@ def resample(x, num, t=None, axis=0, window=None, domain="time"):
N = int(np.minimum(num, Nx))
Y = cp.zeros(newshape, dtype=X.dtype)
sl[axis] = slice(0, (N + 1) // 2)
Y[sl] = X[sl]
Y[tuple(sl)] = X[tuple(sl)]
sl[axis] = slice(-(N - 1) // 2, None)
Y[sl] = X[sl]
Y[tuple(sl)] = X[tuple(sl)]
y = cp.fft.ifft(Y, axis=axis) * (float(num) / float(Nx))

if x.dtype.char not in ["F", "D"]:
Expand Down