Skip to main content

Backend

Trait Backend 

Source
pub trait Backend: Send + Sync {
    // Required method
    fn fft2(
        &self,
        values: &mut [Complex64],
        shape: (usize, usize),
        direction: FftDirection,
        column_scratch: &mut [Complex64],
    ) -> Result<()>;

    // Provided methods
    fn capabilities(&self) -> BackendCapabilities { ... }
    fn resident_backend(&self) -> Option<&dyn ResidentBackend> { ... }
}
Expand description

Minimal backend boundary. Buffers stay owned by reconstruction state.

Required Methods§

Source

fn fft2( &self, values: &mut [Complex64], shape: (usize, usize), direction: FftDirection, column_scratch: &mut [Complex64], ) -> Result<()>

Applies an in-place normalized 2-D FFT to a row-major host buffer.

values must contain height * width elements and column_scratch must fit the larger axis required by the implementation.

Provided Methods§

Source

fn capabilities(&self) -> BackendCapabilities

Reports memory and resident-buffer capabilities.

Source

fn resident_backend(&self) -> Option<&dyn ResidentBackend>

Returns optional resident-buffer operations when declared by Self::capabilities.

Implementors§