Nodes/FiL_Design_ImageMind/🔄 Model Cycler
ComfyUI Node

🔄 Model Cycler

Queue up five checkpoints and let the cycler A/B them for you

By FiL-Design-Ai·Created 2 months ago·Updated 2 days ago· 3
🔄 Model Cycler
  • clip
  • vae
  • model
  • clip
  • vae
  • model_name
  • clean_name
source_modeDiffusion Models
model_list
filter_pattern
cycle_modeSequential (Loop)
index0
auto_advancetrue
unload_previoustrue
free_vramtrue
skip_on_errortrue
weight_dtypedefault

If you've ever wanted to run one prompt across four checkpoints and compare the results side by side, you know the chore: reload the model by hand between every run, or build four parallel loader→sampler chains and babysit which one is queued. 🔄 FiL Model Cycler exists to kill that. It's a loader that doesn't sit still - wire it where a Checkpoint Loader would go, hit queue, and every run it loads the next model in your list, hands the graph the model plus its name, and steps forward for the next run.

Fair warning up front: this is a niche utility from the FiL_Design_ImageMind pack (the repo was originally named FiL_LLM and GitHub still redirects the old URL). It has almost no community footprint yet - no big reddit threads, no viral workflow shares. Doesn't mean it's broken; it just means the README and the code are your documentation, and both are in decent shape.

What it actually does

Drop it into a graph in place of Load Checkpoint, wire its model (and clip/vae) outputs into your sampler and encoder, and let the queue run. Each submission loads the next checkpoint from your list, unloads the previous one from VRAM first, and reports which model it's on in the panel (3/7, etc.). The cycle position is kept in memory per node, so a second cycler in the same graph, another workflow tab, or a copy-pasted node all count their own steps - an earlier design shared one counter between any two equal-length lists, which made A/B comparisons nonsense, and that bug is explicitly fixed in the code comments.

Inputs that matter

  • source_mode - where models come from: Checkpoints or Diffusion Models (UNet). Get this right or you'll "find nothing."
  • model_list - a multiline list of filenames. Leave it empty and the node auto-scans the whole folder; lines starting with # are ignored.
  • filter_pattern - wildcard filter over that list, e.g. *flux* or sdxl*. No wildcard chars? The node wraps your text as *yourtext* anyway.
  • cycle_mode - Sequential (Loop), Sequential (Stop) (halts once it passes the end - handy for a bounded sweep), Ping-Pong, Random, or Fixed Index.
  • index + auto_advance - index is the starting slot; auto_advance (on by default) is what steps to the next model after each run. Flip it off and it's just a model picker.
  • unload_previous / free_vram - both default on, and they're the anti-OOM design: ComfyUI unloads all models and flushes the PyTorch CUDA cache before each swap, so only one model is resident at a time.
  • weight_dtype (optional) - precision for UNet-style models (default, fp16, bf16, fp8_e4m3fn, fp8_e5m2).
  • clip / vae (optional) - fallbacks for diffusion models. A standalone Flux UNet bundles no CLIP or VAE, so you feed those in here and they pass through to the node's clip/vae outputs.

Outputs

model goes to your sampler; clip and vae go to the text encoder and decoder. The two string outputs are the useful extras: model_name is the full filename (juggernautXL_v9.safetensors), clean_name strips the directory and extension (juggernautXL_v9). Wire clean_name into a Save Image filename or a note node and every image in the batch tells you which model made it - that's the whole point of an A/B sweep.

Installing it

It ships in the FiL_Design_ImageMind pack, so this is a pack-level install:

cd ComfyUI/custom_nodes
git clone https://github.com/FiL-Design-Ai/FiL_Design_ImageMind.git
pip install -r FiL_Design_ImageMind/requirements.txt

Or search FiL_Design_ImageMind in ComfyUI Manager and click install. Then restart ComfyUI. Two things to know: the pack needs ComfyUI 0.3.60+ (it's built on the V3 node API) and Python 3.10–3.12, so if the nodes don't show up, update ComfyUI first - that's the most common reason this pack fails to load. The dependencies themselves are light (requests, aiohttp, PyYAML, Pillow, numpy, pydantic) and mostly already present. On Windows, install_requirements.bat in the pack folder installs into ComfyUI's own Python for you. Nothing here downloads model weights - it cycles models you already own.

Where people get burned

  • "No models found" usually means source_mode doesn't match where your file lives. Diffusion Models mode scans models/diffusion_models (falling back to unet); a checkpoint sitting in models/checkpoints needs Checkpoints mode.
  • OOM anyway - unloading between runs stops stacking, but if one single model doesn't fit your card, it still won't load. That's what skip_on_error (on by default) is for: it logs the failure and advances to the next model instead of killing the queue.
  • GGUF UNets load through ComfyUI-GGUF - install that pack too if you cycle quantized flux.
  • Restarting ComfyUI resets every cycler back to its index widget value; the walk position lives in the process, not in the workflow file.
Category🎨 FiL Design/🧰 Tools

Inputs (12)

NameTypeDefaultDescription
source_modeCOMBODiffusion ModelsModel source: Checkpoints, Diffusion Models (UNet), or Connected Signals.
model_listSTRINGMultiline list of model filenames. If empty, auto-scans all installed models in folder.
filter_patternSTRINGWildcard pattern to filter models (e.g. *flux* or sdxl*).
cycle_modeCOMBOSequential (Loop)Iteration order: Sequential (Loop), Sequential (Stop), Ping-Pong, Random, or Fixed Index.
indexINT00–99999Starting 0-based model index (auto-advances per run when Auto Next is ON).
auto_advanceBOOLEANtrueAutomatically switch to next model after each generation run.
unload_previousBOOLEANtrueUnload previous model from GPU memory before loading next model to prevent OOM.
free_vramBOOLEANtrueFlush PyTorch CUDA memory cache between model switches.
skip_on_errorBOOLEANtrueSkip corrupt or missing model files and proceed to next model without crashing queue.
weight_dtypeoptCOMBOdefaultWeight precision for UNet/Diffusion models (default, fp16, bf16, fp8_e4m3fn).
clipoptCLIPPassthrough or fallback CLIP for UNet models.
vaeoptVAEPassthrough or fallback VAE for UNet models.

Outputs (5)

NameTypeDescription
modelMODELActive loaded or selected diffusion model.
clipCLIPActive CLIP (from checkpoint or fallback clip).
vaeVAEActive VAE (from checkpoint or fallback vae).
model_nameSTRINGFull filename of active model (e.g. flux1-dev.safetensors).
clean_nameSTRINGModel name without directory or extension (e.g. flux1-dev).