Skip to content

Frequency to time domain conversion#

Apply a frequency to time domain conversion using a 1D Fast Fourier Transform (FFT) along the time axis of an input 3D cube.

Description#

This script uses xrft.xrft.ifft to compute the inverse FFT. xrft is build on xarray, dask and numpy and preserves netCDF metadata during computations.

Command line interface#

The script needs a single netCDF (3D) as input (in frequency domain):

There are two options to run the script. We recommend using the CLI entry point like:

>>> 14_cube_apply_IFFT /path/to/cube.nc --params_netcdf /path/to/config.yml [optional parameters]
Alternatively, the script can be executed using the (more verbose) command:
>>> python -m pseudo_3D_interpolation.cube_apply_IFFT /path/to/cube.nc \
      --params_netcdf /path/to/config.yml [optional parameters]

Optionally, the following parameters can be specified:

  • --help, -h: Show help.
  • --params_netcdf: Path of netCDF parameter file (YAML format). Required!
  • --compute_real: Compute FFT assuming real input and thus discarting redundant negative frequencies.
  • --verbose {LEVEL}, -V: Level of output verbosity (default: 0).

Last update: Monday, 03 July 2023 at 09:46:51