mixed_fftconv1d_fp32_bhl_chunked#

mixed_fftconv1d_fp32_bhl_chunked(
x,
kernel,
periodic,
shortcut=None,
use_phase_shift=True,
chunk_size=None,
)#

Memory-efficient 1D mixed-BC FFT conv (BHL) via channel chunking.

Produces the same output as mixed_fftconv1d_fp32_bhl() but processes at most chunk_size channels at a time, lowering peak FFT-intermediate memory at the cost of multiple kernel launches.

Parameters:
  • x (Tensor) – Input tensor of shape [B, H, L] (any dtype, cast to fp32).

  • kernel (Tensor) – Kernel tensor of shape [1|B, H, K].

  • periodic (Sequence[bool]) – Length-1 sequence of bools. periodic[0] == True → circular.

  • shortcut (Tensor | None) – Optional per-channel scale [H] added as y += shortcut * x.

  • use_phase_shift (bool) – See mixed_fftconv1d_fp32_bhl().

  • chunk_size (int | None) – Number of channels per chunk. Defaults to _DEFAULT_MIXED_CHUNK_SIZE (128). Pass None to use the default.

Returns:

Tensor of shape [B, H, L] in the original dtype of x.

Return type:

Tensor