ReSWD: ReSTIR‘d, not shaken. Combining Reservoir Sampling and Sliced Wasserstein Distance for Variance Reduction.
This is the official codebase for ReSWD, a state-of-the-art algorithm for distribution matching with reduced variance. It has several applications (such as diffusion guidance or color matching).
The project uses uv for package management. Install it via pip install uv
if not installed.
Then run
uv sync
We support a CLI and gradio demo. The cli can be run with:
uv run -m src
It will then guide you through the different modes
The gradio demo can be executed with
uv run -m src.gradio_demo
In example/test_frames_with_color_patches we have uploaded the test frames, including the mean swatch values from a color checker for error calculations.
@article{boss2025reswd,
title={ReSWD: ReSTIR‘d, not shaken. Combining Reservoir Sampling and Sliced Wasserstein Distance for Variance Reduction.},
author={Boss, Mark and Engelhardt, Andreas and Donné, Simon and Jampani, Varun},
journal={arXiv preprint},
year={2025}
}