Float To Int (Soze)
Fixing the FLOAT-to-INT socket mismatch
- INT
Try to plug a FLOAT output straight into an INT input in ComfyUI and the wire just won't connect - the graph enforces socket types strictly, no auto-casting. That's the entire reason Float To Int exists: it's a one-job adapter that takes a float and hands back an int so the rest of your graph stops complaining.
You'll hit this constantly once you start doing any math or logic inside a workflow. Something upstream - a slider, an expression node, a CLIP-seq-length calculation - spits out a FLOAT, but the node you want to feed (a batch count, a resolution, a seed, a loop index) demands an INT. Rather than rebuilding your math with integer-only nodes, you drop this converter in the middle of the wire and move on.
How it works
There's no real "mechanism" to speak of - it takes the float value on its input and returns it as an integer on its output. What the node's schema doesn't spell out is whether that conversion rounds (4.7 → 5) or truncates (4.7 → 4). Since the pack doesn't document it and it's not the kind of thing worth guessing at, if your workflow is sensitive to the exact boundary (you're converting 3.999 and need to know if you get 3 or 4), wire a test value through to a Show Text/Show Any node before you rely on it in production.
The inputs and outputs that matter
There's exactly one input and one output, so there's nothing to explain beyond what they are:
float- the value to convert. Default0, and the range is effectively unbounded (±1e20) with a0.01step on the widget.- Output:
INT- wire this into whatever integer-typed input was rejecting your float. Batch counts,steps, image dimensions, and loop counters are the usual destinations.
How to install it
Through ComfyUI Manager: search "Quality of Life Nodes for ComfyUI" (or just "Soze") and install. Manually:
cd ComfyUI/custom_nodes
git clone https://github.com/SozeInc/ComfyUI_Soze.git
pip install -r ComfyUI_Soze/requirements.txt
Restart ComfyUI afterward. This particular node has zero extra requirements beyond the base install - it doesn't touch any of the pack's integration features (ComfyDeploy, FAL, ElevenLabs, Azure Blob upload), so you don't need any of the pack's optional API keys to use it.
Common issues & troubleshooting
There isn't much that goes wrong with a converter this small, but two things are worth knowing:
This is a genuinely obscure pack. Across a large Reddit corpus of ComfyUI discussion, ComfyUI_Soze comes up essentially once, and not for this node. If something behaves unexpectedly, you won't find a thread about it - you're better off opening the pack's short Python source directly on GitHub than searching for help, since the node itself is only a handful of lines.
Silent value loss. If you're converting a float that matters (a computed strength, a precise ratio) into an int for a node that only accepts integers, you're throwing away the fractional part one way or another. That's inherent to the conversion, not a bug - if precision matters downstream, keep the float path and only convert at the very last node that actually requires an INT.
Nothing to install beyond the base pack. If ComfyUI reports this node as missing after a Manager install, it usually means the clone didn't complete or requirements.txt didn't run - a plain re-install fixes it faster than debugging around it, since the pack has no models or heavy dependencies to go wrong.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| float | FLOAT | 0.00-100000000000000000000–100000000000000000000 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| INT | INT | — |