fourier_encode

ivy.fourier_encode(x: Union[ivy.Array, ivy.NativeArray], max_freq: float, num_bands: int = 4, linear: bool = False) → Union[ivy.Array, ivy.NativeArray][source]

Pads an array with fourier encodings.

Parameters
  • x (array) – Input array to encode.

  • max_freq (float) – The maximum frequency of the encoding.

  • num_bands (int, optional) – The number of frequency bands for the encoding. Default is 4.

  • linear (bool, optional) – Whether to space the frequency bands linearly as opposed to geometrically. Default is False.

Returns

New array with the final dimension expanded, and the encodings stored in this channel.


Supported Frameworks:

empty jax_logo empty tf_logo empty pytorch_logo empty mxnet_logo empty numpy_logo empty