OpenCV HoughCircles_1
The duplicate copy of circle detection you can just ignore
- image
- circles
- nparray
HoughCircles_1 is functionally identical to HoughCircles_0 - same inputs, same output, same underlying cv2.HoughCircles call, just the second overload that the pack's auto-generator emitted. If you searched for this node because a workflow demanded it, you can swap in the _0 version and nothing changes. Pick whichever, they're interchangeable.
Why the duplicate exists
This pack generates a node per OpenCV function overload, parsed from the .pyi type stubs. cv2.HoughCircles has two bindings in the stubs, and the generator didn't bother deduplicating the ones that resolve to the same signature. Hence HoughCircles_0 and HoughCircles_1, side by side, doing the same thing. ComfyUI's node search will list both; there is no feature difference, no hidden behavior, no reason to prefer one. It's the same story as hasNonZero_0/1 and HoughLines_0/1.
So, the actual algorithm
Read the HoughCircles_0 article for the full walkthrough. Short version: it detects circles by having edge pixels vote on candidate centers and radii, and it returns a shape (N, 1, 3) array of [x, y, radius] detections. The inputs that actually matter are param2 (sensitivity - lower is more circles, more false positives), minRadius/maxRadius (tighten these to kill false positives), and minDist (minimum spacing between detected centers). It needs a grayscale 8-bit nparray on image - feed it the 3-channel BGR result from Image2Nparray and you'll hit the img.type() == CV_8UC1 assertion error. Convert with cvtColor code 6 first.
The output is geometry, not a drawing: to visualize your detected circles you'll need to draw them yourself, e.g. with the pack's circle_0 node. There's no convenience "overlay the circles" node (the author lists it as unfinished in the README).
Install
cd ComfyUI/custom_nodes
git clone https://github.com/geroldmeisinger/opencv-comfyui
or "OpenCV" via ComfyUI Manager, plus pip install opencv-contrib-python. No model files anywhere in this pack.
Bottom line
Use HoughCircles_0 or _1, it genuinely does not matter - they call the same function with the same parameters. If a saved workflow references the _1 name, keep it and move on; if you're building fresh, either works. The only thing that costs you time with circle detection is the parameter tuning and the grayscale conversion, and neither of those is affected by which copy of the node you dragged in.
Inputs (9)
| Name | Type | Default | Description |
|---|---|---|---|
| image | NPARRAY | — | |
| method | INT | — | |
| dp | FLOAT | — | |
| minDist | FLOAT | — | |
| param1 | FLOAT | — | |
| param2 | FLOAT | — | |
| minRadius | INT | — | |
| maxRadius | INT | — | |
| circlesopt | NPARRAY | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| nparray | NPARRAY | — |