torch_fft_rfft | R Documentation |
Computes the one dimensional Fourier transform of real-valued input.
torch_fft_rfft(self, n = NULL, dim = -1L, norm = NULL)
self |
(Tensor) the real input tensor |
n |
(int) Signal length. If given, the input will either be zero-padded or trimmed to this length before computing the real FFT. |
dim |
(int, optional) – The dimension along which to take the one dimensional real FFT. |
norm |
norm (str, optional) – Normalization mode. For the forward transform, these correspond to:
|
The FFT of a real signal is Hermitian-symmetric, X[i] = conj(X[-i])
so the
output contains only the positive frequencies below the Nyquist frequency.
To compute the full output, use torch_fft_fft()
.
if (torch_is_installed()) {
t <- torch_arange(start = 0, end = 3)
torch_fft_rfft(t)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.