π Anime Upscale
The anime upscaler that actually does the work β tiling, AMP, and one fixed x2
- upscale_model_custom
- image
- image
SnJakeAnimeUpscaleInference (display name "π Anime Upscale") is the node that makes the pixels. It takes the model loaded by the pack's checkpoint loader, applies it to your image, and returns it at exactly 2Γ. Not 4Γ, not configurable - x2, fixed. That's actually the right call for a restoration model: the Baikal-Swin-Anime weights were trained to add one clean 2Γ step, and chaining it twice beats asking it for one giant jump.
Where it fits
On the upscaling ladder from the KB, this is the "more detail / restoration" rung - but for flat art, not photos. RealESRGAN anime variants and 4x-AnimeSharp are the fast, no-surprise interpolation option; this is the heavier Swin-transformer restoration model trained on ~50k Danbooru2024 images that rewrites line work and cleans up soft edges. Use it when a source is soft, low-res, or slightly mushy and you want it back to crisp cell-shaded form. Don't use it on photographs - it's an anime model and it will happily anime-ify a face.
How it works
Mechanically it's straightforward under the hood: it moves the image to the chosen device as NCHW, runs the model in inference mode, clamps to 0β1, and returns a [B,H,W,C] tensor. Two things you'll actually feel:
- Tiling.
tile(default 0, disabled) splits large images into overlapping chunks, runs each, and blends them with weighted averaging so seams don't show. This is what keeps a big image from blowing your VRAM. - AMP.
amp(auto/bf16/fp16/none) runs the pass in reduced precision.autopicks bf16 if your card supports it, else fp16. On a Swin net this is basically free speed; leave it on auto unless you're chasing artifacts.
The inputs that actually matter for a beginner:
upscale_model_custom- must come from theπ Anime Upscale Loadernode. This is a customANIME_UPSCALE_MODELtype; a plainUPSCALE_MODELfrom ComfyUI's built-in loader won't plug in.image- your source. Must be 3-channel RGB; the node raisesValueErroron anything else, so strip alpha before feeding it.tile- 0 for small images; 256β512 for anything large, per the tooltip. Start at 256 if a big image OOMs.overlap- tile overlap for smooth blending; the tooltip recommends 32β64 (note the default is 16, lower than recommended - bump it for big tiles).ampanddevice- leave both onauto.devicefalls back to CPU if no CUDA, which will be slow but functional.
The one output, image, is your x2 result. Save it, feed it to a VAE, or chain it into a second pass for 4Γ.
Install and first run
Same as the loader - it's one pack, one install:
cd ComfyUI/custom_nodes
git clone https://github.com/SnJake/SnJake_Baikal_Swin_Anime.git
cd SnJake_Baikal_Swin_Anime
pip install -r requirements.txt
(That requirements.txt is a single line: huggingface_hub.) Or install via ComfyUI Manager, then restart. On the first run the loader auto-downloads the weights to ComfyUI/models/anime_upscale/; if that download stalls, grab the .safetensors from SnJake/Baikal-Swin-Anime manually and drop it in the same folder.
Troubleshooting
Most failures here are wiring, not physics:
- "Upscale model is missing." You fed something that isn't the custom
ANIME_UPSCALE_MODELoutput from SnJake's own loader. Fix the connection, not the node. - "expects 3-channel RGB images." Your image has an alpha channel or is grayscale. Run it through a Remove Background / RGB conversion node first.
- Crunchy edges or noise. The model is explicitly experimental. The V1 checkpoint had edge-noise artifacts (V2 fixed them), and the V3.1
..._x2_v31.safetensorsis the author's "current best." If you're on an old weights_name in the loader, that's your first suspect. - First-run freeze. It's downloading the checkpoint over the network. Watch the console; it prints the download progress there.
This pack has almost no community footprint yet, so you're partly in uncharted territory - but the workflow is genuinely only two nodes long. Loader β Anime Upscale β Save, and you're done.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| upscale_model_custom | ANIME_UPSCALE_MODEL | β | |
| image | IMAGE | β | |
| tile | INT | 00β4096 | Recommended tile size: 256-512 (0 disables tiling). |
| overlap | INT | 160β1024 | Recommended overlap: 32-64. |
| amp | COMBO | auto | 4 options: auto, bf16, fp16, none |
| device | COMBO | auto | 3 options: auto, cuda, cpu |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | β |