Nodes/comfyui_cv/cv2.filterSpeckles
ComfyUI Node

cv2.filterSpeckles

Raw wrapper of cv2.filterSpeckles(img, newVal, maxSpeckleSize, maxDiff). Parameters marked '?' are optional; blank means OpenCV default. See the OpenCV documentation for details.

By bmad4ever·Created 3 months ago·Updated 2 days ago· 0
cv2.filterSpeckles
  • img
  • img
  • buf
newVal0.0000
maxSpeckleSize0
maxDiff0.0000
Categoryimage/CV/low-level/cv2 F

Inputs (4)

NameTypeDefaultDescription
imgNPARRAY,IMAGE,MASKThe input 16-bit signed disparity image Accepts a ComfyUI IMAGE/MASK directly (frame 0 of a batch) or an NPARRAY. Arithmetic ops (add, multiply, etc.) process the full IMAGE batch when both inputs have the same batch size.
newValFLOAT0.0000-1e+38–1e+38The disparity value used to paint-off the speckles
maxSpeckleSizeINT0-2147483648–2147483647The maximum speckle size to consider it a speckle. Larger blobs are not affected by the algorithm
maxDiffFLOAT0.0000-1e+38–1e+38Maximum difference between neighbor disparity pixels to put them into the same blob. Note that since StereoBM, StereoSGBM and may be other algorithms return a fixed-point disparity map, where disparity values are multiplied by 16, this scale factor should be taken into account when specifying this parameter value.

Outputs (2)

NameTypeDescription
imgNPARRAY
bufNPARRAY