Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

np.longcomplex and np.complex_ are replaced #102

Merged
merged 1 commit into from
May 30, 2024
Merged
Changes from all commits
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
8 changes: 4 additions & 4 deletions mkl_fft/_float_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,15 +59,15 @@ def __downcast_float128_array(x):
xdt = x.dtype
if xdt == np.longdouble and not xdt == np.float64:
return np.asarray(x, dtype=np.float64)
elif xdt == np.clongdouble and not xdt == np.complex_:
return np.asarray(x, dtype=np.complex_)
elif xdt == np.clongdouble and not xdt == np.complex128:
return np.asarray(x, dtype=np.complex128)
if not isinstance(x, np.ndarray):
__x = np.asarray(x)
xdt = __x.dtype
if xdt == np.longdouble and not xdt == np.float64:
return np.asarray(x, dtype=np.float64)
elif xdt == np.longcomplex and not xdt == np.complex_:
return np.asarray(x, dtype=np.complex_)
elif xdt == np.clongdouble and not xdt == np.complex128:
return np.asarray(x, dtype=np.complex128)
return __x
return x

Expand Down