Fast Style Transfer
Old-school painterly effects in about 0.3 seconds
- content_img
- IMAGE
Before IP-Adapter and before anyone in ComfyUI was doing "style transfer" with adapters, this is how it was done: a small neural network that repaints any image in a fixed style, no diffusion involved. FastStyleTransfer is the inference half of that idea. Feed it a content image, pick one of the bundled style models, and it returns a stylized IMAGE in roughly a third of a second on a modest GPU. On an RTX 2060, the author measured about 0.3 seconds - fast enough that he suggested realtime video stylization in theory.
So what is this actually for? It's not a flexible style-transfer tool in the way you might be used to. Each of the seven bundled .pth models (udnie, lazy, mosaic, bayanihan, starry, wave, tokyo_ghoul) is one locked-in aesthetic. You don't feed it a style image per run - you pick a style, and every image that goes through it comes out in that style. That makes it great for consistency (batch-stylizing a whole image set so they look unified) and bad for "just match this reference." If you want per-image style matching, that's the other node in this pack, NeuralStyleTransfer, or an IP-Adapter.
How it works
Under the hood it loads a TransformerNetwork - the feedforward architecture from Johnson et al.'s 2016 "Perceptual Losses for Real-Time Style Transfer": three conv blocks, five residual blocks, three deconv blocks, instance normalization, no tanh. This is the same network family that the bundled models were trained with, so inference is a single forward pass over the whole image. No iterative optimization, no per-image training. The style is baked into the weights.
The inputs that matter
Only two, which is the whole point:
content_img(IMAGE) - whatever you want repainted. Wire aLoadImagein, or any other node that emits an IMAGE.model- a dropdown of the.pthfiles sitting in the pack'smodels/folder. Seven ship with the pack; any model you train with the sibling TrainFastStyleTransfer node (or drop in from the original rrmina repo) appears here too.
The single output is IMAGE, which feeds straight into SaveImage or anything else downstream that takes an image. Since it's pure pixel transformation and touches no checkpoint, you can drop it in the middle of a workflow to stylize an output before it's saved.
Installing it
ComfyUI Manager can find it by searching "ComfyUI-Fast-Style-Transfer", or:
cd ComfyUI/custom_nodes
git clone https://github.com/zeroxoxo/ComfyUI-Fast-Style-Transfer
then restart ComfyUI. The models ship with the repo - there's nothing extra to download for inference, and no heavy dependency beyond torch, which ComfyUI already has. The author's whole pitch was that the implementation is light enough to eyeball for safety, and it is: the node file is a few hundred lines of straightforward torch.
Where people get burned
The node reads models from a hardcoded path: ComfyUI/custom_nodes/ComfyUI-Fast-Style-Transfer/models/. Clone it under a different folder name and the model dropdown silently lists nothing, because it's scanning that exact directory. Also note that your trained models must live in that folder - not ComfyUI's models/ directory - or the dropdown won't see them. That's the kind of thing that has people convinced the node is broken when it's really just a path quirk.
A fair warning on expectations: this is the old-school look. Styles are painterly and obvious, not subtle. If you want a light aesthetic nudge, this is a hammer. But if you want a cheap, deterministic, GPU-cheap stylization pass with zero diffusion cost, it's hard to beat.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| content_img | IMAGE | — | |
| model | COMBO | 7 options: udnie.pth, lazy.pth, mosaic.pth, bayanihan.pth, starry.pth, wave.pth, +1 |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |