import dascore as dc
patch = dc.get_example_patch()
# perform dft (fft) on time axis
dft_time = patch.dft(dim="time")
# get inverse dft, transformed axis are ascertained automatically
idft = dft_time.idft()Idft
Idft(
*args ,
dim: Any = None,
)-> None
Perform the inverse discrete Fourier transform (idft) on specified dimension(s).
Currently, only patches transformed with dft can be inverted. After dft, the transformed coordinates must not change (e.g., with select), otherwise idft won’t work.
Parameters
| Parameter | Description |
|---|---|
| dim |
A single, or multiple dimensions over which to perform idft. If None, perform idft over all dimensions that have names starting with “ft_”, which indicates they have already undergone a fourier transform. |
Note
Real transforms are determined by transformed coordinates which have no negative values.
Non-dimensional coordinates measured on a transformed dimension are restored with it, provided the patch still carries what dft parked for them. One spanning more than one dimension is not parked, so it does not come back.
See the FFT note in Notes section of DASCore’s documentation.
See Also
Examples
Methods
| Name | Description |
|---|---|
| check | Refuse a patch which does not carry what the operation needs. |
| get_metadata | Return the restored metadata, and the axes, sizes and trim. |
| kernel | Return the inverse transform, trimmed of the padding dft added. |
| model_copy | Copy the model, dropping cached values the update invalidates. |
| new | Create new instance with some attributed updated. |
| idft | Perform the inverse discrete Fourier transform (idft) on specified dimension(s). |
| reconcile | Return metadata or a patch holding the final data; default as is. |
| run | Run the operation: check, get_metadata, kernel, reconcile, record. |