/
githubmirror
/
scikit-learn
Обзор
Документация
Войти
/
githubmirror
/
scikit-learn
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
sklearn/externals/array_api_compat/cupy/fft.py
35 строк
872 B
Lucas Colley
MNT: externals: bump array-api-compat to v1.13 (#32962)
05 янв 2026, 12:30
Не верифицирован
05 янв 2026, 12:30
932c8bf
Код
Авторство
О чём код?
from cupy.fft import * # noqa: F403 # cupy.fft doesn't have __all__. If it is added, replace this with # # from cupy.fft import __all__ as linalg_all _n: dict[str, object] = {} exec("from cupy.fft import *", _n) del _n["__builtins__"] fft_all = list(_n) del _n from ..common import _fft from .._internal import get_xp import cupy as cp fft = get_xp(cp)(_fft.fft) ifft = get_xp(cp)(_fft.ifft) fftn = get_xp(cp)(_fft.fftn) ifftn = get_xp(cp)(_fft.ifftn) rfft = get_xp(cp)(_fft.rfft) irfft = get_xp(cp)(_fft.irfft) rfftn = get_xp(cp)(_fft.rfftn) irfftn = get_xp(cp)(_fft.irfftn) hfft = get_xp(cp)(_fft.hfft) ihfft = get_xp(cp)(_fft.ihfft) fftfreq = get_xp(cp)(_fft.fftfreq) rfftfreq = get_xp(cp)(_fft.rfftfreq) fftshift = get_xp(cp)(_fft.fftshift) ifftshift = get_xp(cp)(_fft.ifftshift) __all__ = fft_all + _fft.__all__ def __dir__() -> list[str]: return __all__