Nodes/ComfyUI-MDSNodes/ControlNet Select
ComfyUI Node

ControlNet Select

Your ControlNet Name, Turned Into Text You Can Actually Use

By MarwanDSAI·Created about a month ago·Updated a day ago· 1
ControlNet Select
    • control_net_name
    • control_net_name (STRING)
    • control_net_name_no_ext (STRING)
    control_net_name

    The Load ControlNet Model node already gives you a dropdown, so why would you ever need a second one that picks the same file? Because the built-in loader keeps the model name trapped inside the node. ControlNet Select hands you that name as a wire - the raw combo value, the full filename as text, and the filename with the extension stripped - and you can route it anywhere a string is welcome.

    This is one of those utility nodes that makes no sense until you're building a model-testing workflow, which is exactly what this pack is for. When you're A/B-ing a dozen ControlNets across renders, you want the filename written into your output metadata or your save filename so you can look at a folder of results and know instantly which condition produced which image. ControlNet Select exists to make that one line of logging automatic.

    How it works

    Mechanically it's almost nothing, and that's the appeal. The node reads folder_paths.get_filename_list("controlnet"), so the dropdown is populated from everything in ComfyUI/models/controlnet/. When you pick one, it returns the same string three ways: the raw selection (typed *, so it can plug into anything that expects a ControlNet name or a combo slot), the full filename as a STRING (like control_v11p_sd15_canny.pth), and the name with the extension chopped off via os.path.splitext (so control_v11p_sd15_canny).

    The three outputs and what they're for

    • control_net_name (*) - wire this into the control_net_name input of a Load ControlNet Model. It's the "just make it connect" output, and it's the one you'll use for the actual generation path.
    • control_net_name (STRING) - the full filename as plain text. Feed it into a filename prefix, a metadata string, or a save node.
    • control_net_name_no_ext (STRING) - same thing minus the extension. Handy when you want a cleaner label than a .pth trailing after your tag.

    One input, control_net_name, and it's just the dropdown. Nothing else to set.

    Using it well

    The useful habit: keep the * output on the generation line and drag the STRING output to wherever you build your save filename or metadata. Then every render is self-documenting. And since this is a selector rather than a loader, remember it doesn't actually load anything - pair it with a real Load ControlNet Model. If you're new to ControlNet generally, know that the dropdown is only half the story: the weight (0.3–0.7 for loose guidance, 0.8–1.2 for strict) and the starting/ending step controls are where you actually dial in behavior. This node just makes sure you know which ControlNet you used while you're doing it.

    Installing it

    Part of the MarwanDSAI/comfyui-mdsnodes pack, so it installs with the whole thing. ComfyUI Manager is the easy route - search "ComfyUI-MDSNodes" and hit Install, then restart. By hand:

    cd ComfyUI/custom_nodes
    git clone https://github.com/MarwanDSAI/comfyui-mdsnodes
    

    Then restart ComfyUI. There are no Python dependencies to install - requirements.txt is empty and the package declares zero deps, so this one won't fight your other nodes.

    Gotchas

    If your dropdown comes up empty, your models/controlnet folder is empty - go grab the model file first. And if you try to jam the * output into a node that expects a strict STRING and it won't connect, that's normal: use the STRING output instead. The wildcard output is for combo slots and any-type inputs, not for text sockets.

    CategoryMDSNodes/utils/

    Inputs (1)

    NameTypeDefaultDescription
    control_net_nameCOMBOSelect a ControlNet model file from your models/controlnet directory.

    Outputs (3)

    NameTypeDescription
    control_net_name*Passes the raw combo selection to nodes expecting a ControlNet name.
    control_net_name (STRING)STRINGThe full filename as a standard STRING (e.g. 'control_v11p_sd15_canny.pth').
    control_net_name_no_ext (STRING)STRINGThe filename without the file extension as a STRING (e.g. 'control_v11p_sd15_canny').