Nodes/Boyonodes/🧪 Solver Switch (Experimental)
ComfyUI Node

🧪 Solver Switch (Experimental)

One Sampler That Changes Which Solver Runs Each Step

By DragonDiffusionbyBoyo·Created 2 years ago·Updated 4 days ago· 17
🧪 Solver Switch (Experimental)
    • sampler
    â—„solverseuler heun dpmpp_2mâ–º
    â—„strategyround_robinâ–º
    â—„seed42â–º
    â—„weightsâ–º

    Every sampler you pick in ComfyUI runs the same algorithm for every step of the denoise. Euler is Euler for all twenty steps; DPM++ 2M is DPM++ 2M throughout. BoyoExperimentalSolverSwitch asks a slightly unhinged question: what if the solver could change mid-run, step by step? It wraps a list of existing k-diffusion solvers and routes each step to a different one according to a strategy you choose. The author is refreshingly honest about the safety story - no new arithmetic, every solver called is existing, validated k-diffusion code, so the risk is the same as using those solvers individually.

    Mechanically it's a per-step router. You give it a list of solver names, it slices the sigma schedule into a two-element window per step, and hands that window to whichever solver the strategy picks. The available solvers are the familiar ComfyUI lineup - euler, euler_a, heun, dpm_2, dpm_2_a, dpmpp_2s_a, dpmpp_2m, dpmpp_sde, dpmpp_3m_sde, lms, lcm - and the switching happens between them without modifying any of their internals.

    The inputs that matter:

    • solvers - a multiline (or comma-separated) list of solver names. Default is euler / heun / dpmpp_2m. Names must match the list exactly or the node can't route.
    • strategy - round_robin cycles through your list in order (step 0 uses solver[0], step 1 uses solver[1], …); random_seeded picks a solver per step from a seeded RNG, so it's reproducible given the same seed and list; weighted_random biases that randomness with per-solver weights.
    • seed - feeds the random strategies; ignored by round_robin.
    • weights - optional, comma-separated, and only read for weighted_random. Must have the same count as the solver list; 1,2,1 favours the second solver twice over.

    Output is a single sampler object, dropped into SamplerCustomAdvanced (the preferred target) or KSamplerSelect, exactly where a normal sampler goes.

    The honest take

    This is a curiosity tool with a real but narrow use. Mixing solvers mid-run is not a path to "better" - it's a way to explore texture and variance, especially since ancestral solvers like euler_a and dpmpp_sde inject noise per step and are inherently more creative. Some people genuinely enjoy round-robin Euler/Euler A blends for stylized video frames. But if you're chasing quality on a flow model, the concepts here still apply: the scheduler matters more than the sampler, and this node only changes the sampler - it doesn't touch your sigma schedule at all.

    Where people get burned:

    • Typo in a solver name and the node refuses to route; the available names are fixed, so copy them from the list above or the tooltip.
    • weighted_random with a weights string that doesn't match the solver count is a hard error, not a silent shrug.
    • The seed only controls solver choice, not the image seed. Same overall seed but different solver lists will still reproduce if you keep the list identical - but changing the list changes the trajectory, obviously.
    • It's a BoyoNodes/Experimental node with no community track record. If a workflow from the wild demands it and you'd rather not gamble, bypass it - there's no penalty to running one solver straight.

    Installing it

    Part of the Boyonodes kitchen sink, installed once:

    cd ComfyUI/custom_nodes
    git clone https://github.com/DragonDiffusionbyBoyo/Boyonodes
    

    or search Boyonodes in ComfyUI Manager, then restart. It's pure torch plus ComfyUI's own comfy.k_diffusion - zero extra pip requirements. If the whole pack is absent after install, the recurring pack failure mode applies: some audio/video module blew up the import, so read the first console traceback and install what it names.

    Fun to play with, occasionally delightful for stylistic runs, and completely optional. Treat it as a toy with a serious manual - that's what the Experimental prefix is for.

    CategoryBoyoNodes/Experimental

    Inputs (4)

    NameTypeDefaultDescription
    solversSTRINGeuler heun dpmpp_2mOne solver name per line (or comma-separated). Available: euler, euler_a, heun, dpm_2, dpm_2_a, dpmpp_2s_a, dpmpp_2m, dpmpp_sde, dpmpp_3m_sde, lms, lcm
    strategyCOMBOround_robinround_robin: cycles through solvers in order. random_seeded: reproducible random selection per step. weighted_random: biased random — set weights below.
    seedINT420–18446744073709550000Seed for random/weighted strategies. Ignored for round_robin.
    weightsoptSTRINGComma-separated weights for weighted_random strategy. Must have the same count as the solver list. E.g. '1,2,1' favours the second solver 2× over the others. Ignored for other strategies.

    Outputs (1)

    NameTypeDescription
    samplerSAMPLER—