mindscience.sciops.fft.ASD_RFFT
- class mindscience.sciops.fft.ASD_RFFT[source]
1D real-to-complex FFT transform using Ascend NPU acceleration.
This operator performs 1D Real Fast Fourier Transform on real input tensors, optimized for Ascend NPU hardware acceleration.
- Inputs:
xr (Tensor): Input real tensor with data type float32.
- Outputs:
yr (Tensor): Real part of output complex tensor with data type float32.
yi (Tensor): Imaginary part of output complex tensor with data type float32.
- Raises
ValueError – If input tensor data type is not float32.
Examples
>>> import mindspore as ms >>> from mindscience.sciops.fft import ASD_RFFT >>> xr = ms.Tensor([[1.0, 2.0, 3.0, 4.0]], ms.float32) >>> asd_rfft = ASD_RFFT() >>> yr, yi = asd_rfft(xr) >>> print(yr.shape) (1, 3) >>> print(yi.shape) (1, 3)