🔎APISR
Anime upscaling that's actually fast (no, there's no API)
- pipe
- image
- IMAGE
The name is a lie, but in the good direction: APISR doesn't call any API, needs no key, and runs entirely on your GPU. It stands for "Anime Production Inspired Super-Resolution," a 2024 CVPR paper built around one idea - anime artwork degrades in ways that photos don't, so you shouldn't upscale it with a model trained on photos. This node runs the official weights, and it's one of the fastest ways to make a clean 4x anime image or video in ComfyUI. If your content is line art, flats, or cel animation, this is a tool worth having next to the usual ESRGAN suspects.
Where it sits in the upscaler zoo: this is a "more pixels" model, not a "invent detail" model. It sharpens lines and cleans compression damage rather than hallucinating texture, which is exactly right for anime and wrong for photos (it'll smooth a real photo into something waxy). For the same job you'd otherwise reach for RealESRGAN_x4plus_anime_6B - APISR is faster and, on actual anime, usually cleaner. It comes in 2x and 4x flavors; this node upscales whatever model its pipe feeds it.
How it works
The model itself comes from the pack's ModelLoader node, which hands you a ready-to-run generator wrapped in the custom APISRMODEL type. This node takes that generator plus your image batch, moves both to your GPU, and runs the whole batch through the model in one shot. That's the batch design: fast on a single image or a short video clip, but the longer the video, the more frames pile up in VRAM at once.
Two inputs matter, and both are beginner-safe:
- crop_for_4x (default
true) - trims the image height and width down to a multiple of 4 before inference. The 4x model needs dimensions it can divide evenly, and this silently handles the edge case where your source is, say, 1001px wide. Leave it on; the worst it does is shave a few pixels off one edge. - dtype (
float32/float16) - casts both the model weights and the input.float16is half the VRAM and visibly faster with no quality penalty you'll notice on line art;float32if you're pixel-peeping.
Plus pipe (from the ModelLoader) and image (any IMAGE tensor - a still, a batch, or frames straight out of a video loader). Output is a single IMAGE tensor, upscaled by the model's scale factor (2x or 4x), ready to wire into a save node or a Video Helper Suite Video Combine.
Install
Easiest via ComfyUI Manager - search "APISR" and install "ComfyUI-APISR". Manual route:
cd ComfyUI/custom_nodes
git clone https://github.com/ZHO-ZHO-ZHO/ComfyUI-APISR
cd ComfyUI-APISR
pip install -r requirements.txt
Then restart ComfyUI. The model files are not downloaded for you - see the ModelLoader article; you grab two .pth files into ComfyUI/models/apisr by hand.
Common issues
- Out of memory on long video. This is the batch node's whole tradeoff. The README says it plainly: frame-heavy videos need high VRAM. If you're blowing up on a 200-frame clip, switch to the APISR Lterative node, which runs the same model frame by frame.
- Model won't load. The loader only accepts two exact filenames. Anything else in the dropdown errors - check the ModelLoader article.
- ImportError mentioning
cv2oromegaconfat startup. The requirements.txt lists onlytimmandfairscale, but the code imports bothopencv-pythonandomegaconfat module load.pip install opencv-python omegaconfand restart.
One honest caveat: this pack is from early 2024 and hasn't been touched since May of that year. It still works - it's a stable wrapper around fixed model weights - but if your source is a fuzzy low-res screencap you want restored, you'd want SeedVR2-class tools, not this. APISR's job is clean anime going bigger, fast.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| pipe | APISRMODEL | — | |
| image | IMAGE | — | |
| crop_for_4x | BOOLEAN | true | — |
| dtype | COMBO | 2 options: float32, float16 |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |