Nodes/comfyui-fvmtools/Person Selector (Match)
ComfyUI Node

Person Selector (Match)

Matches a reference person in the current image using InsightFace (ArcFace) embeddings. Outputs similarity score, match boolean, and optional mask (face/head/body). Body mask requires SAM model from Impact Pack SAMLoader. Face/head masks use BiSeNet segmentation. threshold: minimum cosine similarity for a match (0.6-0.7 recommended) aggregation: how to combine scores across multiple reference images det_size: face detection resolution — higher finds smaller faces but uses more VRAM

By ping1979ping·Created 5 months ago·Updated 2 months ago· 0
Person Selector (Match)
  • current_image
  • reference_images
  • sam_model
  • similarity
  • match
  • mask
  • best_reference
  • face_count
  • matched_face_index
  • report
threshold0.65
aggregation
mask_mode
mask_fill_holestrue
mask_blur0
det_size
CategoryFVM Tools/Face

Inputs (9)

NameTypeDefaultDescription
current_imageIMAGE
reference_imagesIMAGE
thresholdFLOAT0.650–1Minimum cosine similarity to count as match (0.6-0.7 recommended)
aggregationCOMBOHow to combine similarity scores across multiple reference images
mask_modeCOMBOnone=no mask, face=skin only, head=face+hair, body=full body (needs SAM)
mask_fill_holesBOOLEANtrueFill holes inside the mask (closes gaps in segmentation)
mask_blurINT00–100Gaussian blur radius for mask edges
det_sizeCOMBOFace detection resolution — higher finds smaller faces but uses more VRAM
sam_modeloptSAM_MODEL(opt) SAM model from Impact Pack SAMLoader — required for body mask mode

Outputs (7)

NameTypeDescription
similarityFLOAT
matchBOOLEAN
maskMASK
best_referenceIMAGE
face_countINT
matched_face_indexINT
reportSTRING