Color Transfer with Modulated Flows
Maria Larchenko, Alexander Lobashev, Dmitry Guskov, Vladimir Vladimirovich Palyulin
TL;DR
This work introduces ModFlows, a color-transfer method that casts color adjustment as an invertible transport in RGB using rectified neural ODEs. By learning a shared intermediate distribution and an encoder that predicts modulated flow weights, the model generalizes to new content–style pairs without retraining and processes 4K images with strong style and content fidelity. The two-stage training—building a rectified-flow dataset and distilling an encoder to predict flow weights—yields an image-palette embedding capable of rapid inference. Quantitative results on diverse datasets show competitive to state-of-the-art style transfer performance with favorable artifact control, and the 4K capability broadens practical applicability. The framework further points to broader uses in distribution-to-distribution transfers beyond color and to applications requiring invertible, data-driven transport in RGB space.
Abstract
In this work, we introduce Modulated Flows (ModFlows), a novel approach for color transfer between images based on rectified flows. The primary goal of the color transfer is to adjust the colors of a target image to match the color distribution of a reference image. Our technique is based on optimal transport and executes color transfer as an invertible transformation within the RGB color space. The ModFlows utilizes the bijective property of flows, enabling us to introduce a common intermediate color distribution and build a dataset of rectified flows. We train an encoder on this dataset to predict the weights of a rectified model for new images. After training on a set of optimal transport plans, our approach can generate plans for new pairs of distributions without additional fine-tuning. We additionally show that the trained encoder provides an image embedding, associated only with its color style. The presented method is capable of processing 4K images and achieves the state-of-the-art performance in terms of content and style similarity. Our source code is available at https://github.com/maria-larchenko/modflows
