← back

yum/vfft

git clone https://git.yummers.dev/yum/vfft

yumVersion bumpabf4a25

master
5 folders5 files

files

baselines/
benches/
measurements/
shaders/
src/
.gitignore76 B
Cargo.toml1009 B
LICENSE1.0 KiB
README.md1.2 KiB
build.rs4.1 KiB

vfft

vfft is a very fast fourier transform implementation. It currently optimizes for small, power-of-two inputs sizes.

vfft is under heavy development. If you are in need of a high-quality CPU-based FFT, use rustfft. If you need a GPU-based one, use VkFFT.

The goal of this project is to define simple, state-of-the-art fft implementations for small input sizes (under ~8k). My current north star is to meet or exceed VkFft's peformance for workloads where the FFT input and output remains resident on the GPU. This is useful for realtime audio-reactive graphics and ocean wave simulations, and probably more. Eventually, I would also like to implement a world-class CPU implementation, but this is a secondary concern.

Portability

MacOS and Linux are confirmed to work. Windows not tested.

API

use num::Complex;
use vfft::cpu::{ExecutionPlan, fft};
...
let mut data: Vec<Complex<f32>> = ...;
let mut plan = ExecutionPlan::new(data)?;
fft(&mut result_fft, &mut plan);

Testing

# Accuracy
$ cargo test -- --no-capture
# Performance
$ cargo bench

AI Disclosure

This source code was written by a human and checked for errors with an LLM.

License.

MIT License.