← Latest papers
💻 computer science

Color Conditional Generation with Sliced Wasserstein Guidance

The paper introduces SW-Guidance, a training-free method that enhances color-conditional image generation by modifying the diffusion sampling process with Sliced Wasserstein distance to ensure generated images simultaneously match a reference color palette and maintain semantic coherence with the text prompt.

Original authors: Alexander Lobashev, Maria Larchenko, Dmitry Guskov

Published 2026-05-04
📖 4 min read☕ Coffee break read

Original authors: Alexander Lobashev, Maria Larchenko, Dmitry Guskov

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

Imagine you are an artist trying to paint a picture based on a description like "a cat sitting on a rug." You have a great imagination, but you struggle with colors. You want the cat to be a specific shade of "midnight blue" and the rug to be "burnt orange," but when you ask your AI assistant to draw it, the cat ends up being a random gray and the rug turns out to be a muddy brown.

You might think, "Okay, I'll just take the picture the AI made and paint over it to match the colors I want." But here's the problem: if you just force the colors to match, the AI might get confused. It might turn the cat's fur into a blue texture that looks like water, or make the rug look like a field of orange flowers. The colors are right, but the feeling of the objects is lost.

This is the problem the paper "Color Conditional Generation with Sliced Wasserstein Guidance" (or SW-Guidance) tries to solve.

The Problem: "Style" vs. "Color"

Current AI art tools are great at following instructions, but they are terrible at describing specific colors. If you say "turquoise," the AI might give you anything from light blue to green. If you try to fix this by taking a reference photo (like a photo of a sunset) and forcing the AI to copy its colors, older methods often copy everything from that photo. They might copy the sunset's clouds, the texture of the sand, or the way the light hits the water, even if you only wanted the colors.

The Solution: A "Color Filter" that Doesn't Smear the Image

The authors created a new method called SW-Guidance. Think of it as a very smart, invisible filter that sits inside the AI's brain while it is drawing.

Here is how it works, using a simple analogy:

1. The "Sliced" Approach (The Bread Analogy)
Imagine you have two loaves of bread. One is your AI's current drawing, and the other is your reference photo (the one with the perfect colors you want).

  • Old methods tried to compare the whole loaves at once. This is messy and often leads to the AI copying the wrong things (like the crust texture).
  • SW-Guidance takes a knife and slices both loaves into thin strips. It compares the color distribution of just one slice at a time. It does this from many different angles (like slicing the bread vertically, horizontally, and diagonally).
  • By looking at these "slices" (which the paper calls Sliced Wasserstein distance), the AI can see exactly how the colors are distributed without getting confused by the shapes or textures. It's like checking if the flavor of the bread matches, rather than checking if the crust looks the same.

2. The "Guidance" (The GPS Analogy)
As the AI draws the picture step-by-step (starting from static noise and slowly revealing an image), this method acts like a GPS.

  • Every few steps, the GPS checks: "Is the color palette of this drawing getting closer to the reference photo?"
  • If the AI is drifting off course (e.g., making the sky too green), the GPS gently nudges the drawing back toward the correct color distribution.
  • Crucially, it only nudges the colors. It doesn't tell the AI to change the cat into a dog or the rug into a forest. It keeps the "cat-ness" and "rug-ness" intact while fixing the paint.

Why This is Special

The paper claims this method is training-free. This means you don't have to teach the AI a new language or show it thousands of examples of "blue cats." You just give it the text prompt and the reference photo, and the math does the rest.

The Results:

  • Better Color Match: The colors in the final image are much closer to the reference photo than with other methods.
  • No Unwanted Copying: Unlike other methods that might accidentally copy the "vibe" or texture of the reference photo (like copying a brushstroke style), this method only copies the colors.
  • Stays True to the Prompt: The image still looks exactly like what you asked for in your text description (e.g., a cat on a rug), not a copy of the reference photo.

In Summary

The authors built a tool that lets you say, "Draw me a cat, but use the exact color palette from this photo of a sunset," without the AI accidentally turning the cat into a sunset or copying the clouds. It does this by mathematically "slicing" the color information and guiding the AI to match those slices perfectly, ensuring the colors are right without messing up the picture.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →