Nodes Browser

AddLabel
AppendInstanceDiffusionTracking
BatchCLIPSeg
BatchCropFromMask
BatchCropFromMaskAdvanced
BatchUncrop
BatchUncropAdvanced
BboxToInt
BboxVisualize
CameraPoseVisualizer
CheckpointPerturbWeights
ColorMatch
ColorToMask
CondPassThrough
ConditioningMultiCombine
ConditioningSetMaskAndCombine
ConditioningSetMaskAndCombine3
ConditioningSetMaskAndCombine4
ConditioningSetMaskAndCombine5
CreateAudioMask
CreateFadeMask
CreateFadeMaskAdvanced
CreateFluidMask
CreateGradientFromCoords
CreateGradientMask
CreateInstanceDiffusionTracking
CreateMagicMask
CreateShapeImageOnPath
CreateShapeMask
CreateShapeMaskOnPath
CreateTextMask
CreateTextOnPath
CreateVoronoiMask
CrossFadeImages
CustomControlNetWeightsFluxFromList
CustomSigmas
DifferentialDiffusionAdvanced
DownloadAndLoadCLIPSeg
DrawInstanceDiffusionTracking
DummyOut
EmptyLatentImageCustomPresets
EmptyLatentImagePresets
FilterZeroMasksAndCorrespondingImages
FlipSigmasAdjusted
FloatConstant
FloatToMask
FloatToSigmas
FluxBlockLoraLoader
FluxBlockLoraSelect
GLIGENTextBoxApplyBatchCoords
GenerateNoise
GetImageRangeFromBatch
GetImageSizeAndCount
GetImagesFromBatchIndexed
GetLatentsFromBatchIndexed
GetMaskSizeAndCount
GradientToFloat
GrowMaskWithBlur
INTConstant
ImageAddMulti
ImageAndMaskPreview
ImageBatchMulti
ImageBatchRepeatInterleaving
ImageBatchTestPattern
ImageConcanate
ImageConcatFromBatch
ImageConcatMulti
ImageGrabPIL
ImageGridComposite2x2
ImageGridComposite3x3
ImageGridtoBatch
ImageNormalize_Neg1_To_1
ImagePadForOutpaintMasked
ImagePadForOutpaintTargetSize
ImagePass
ImageResizeKJ
ImageTransformByNormalizedAmplitude
ImageUpscaleWithModelBatched
InjectNoiseToLatent
InsertImageBatchByIndexes
InsertImagesToBatchIndexed
InterpolateCoords
Intrinsic_lora_sampling
JoinStringMulti
JoinStrings
LoadAndResizeImage
LoadImagesFromFolderKJ
LoadResAdapterNormalization
MaskBatchMulti
MaskOrImageToWeight
MergeImageChannels
ModelPassThrough
NormalizedAmplitudeToFloatList
NormalizedAmplitudeToMask
OffsetMask
OffsetMaskByNormalizedAmplitude
PlotCoordinates
PointsEditor
PreviewAnimation
RemapImageRange
RemapMaskRange
ReplaceImagesInBatch
ResizeMask
ReverseImageBatch
RoundMask
SV3D_BatchSchedule
SaveImageWithAlpha
ScaleBatchPromptSchedule
Screencap_mss
Sleep
SomethingToString
SoundReactive
SplineEditor
SplitBboxes
SplitImageChannels
StabilityAPI_SD3
StableZero123_BatchSchedule
StringConstant
StringConstantMultiline
Superprompt
VRAM_Debug
WebcamCaptureCV2
WeightScheduleConvert
WeightScheduleExtend
WidgetToString

FilterZeroMasksAndCorrespondingImages

FilterZeroMasksAndCorrespondingImages

Node Information

Category:
KJNodes/masking
Python Module:
custom_nodes.ComfyUI-KJNodes
Output Node:
No
FilterZeroMasksAndCorrespondingImages
PREVIEW
non_zero_masks_out
non_zero_mask_images_out
zero_mask_images_out
zero_mask_images_out_indexes
masks
MASK
original_images
IMAGE
Filter out all the empty (i.e. all zero) mask in masks Also filter out all the corresponding images in original_images by indexes if provide original_images (optional): If provided, need have same length as masks.