Nodes/ComfyUI-LASED-mask/LASED Multi-Seed
ComfyUI Node

LASED Multi-Seed

Runs one LASED swarm per seed point and merges the edge fields (element-wise max) and masks (union) into a full-image contour map.

By MushroomFleet·Created 2 months ago·Updated 2 months ago· 0
LASED Multi-Seed
  • image
  • edge_map
  • mask
seeds64,64; 192,128
tolerance40.0
ants250
steps600
color_spacergb
handboth
beta4.0
epsilon0.05
seed0
modemasking
mask_threshold0.15
sticky_threshold0.20
freeze_after0
no_decayfalse
max_side512
CategoryLASED

Inputs (16)

NameTypeDefaultDescription
imageIMAGE
seedsSTRING64,64; 192,128Spawn points as 'x,y; x,y; ...' in input-image pixels. Each point gets its own swarm and target colour.
toleranceFLOAT40.01–250Colour tolerance (tau). Lower = tighter region. Lab distances run smaller; try 10-25 there.
antsINT2501–5000
stepsINT6001–20000Simulation ticks. More steps = cleaner, more complete contours.
color_spaceCOMBOrgb3 options: rgb, weighted, lab
handCOMBObothWall-following handedness; 'both' splits the swarm into clockwise and counter-clockwise cohorts.
betaFLOAT4.00.1–12Softmax temperature. Higher = greedier edge following.
epsilonFLOAT0.050–0.5Random-move floor; prevents the swarm freezing.
seedINT00–18446744073709550000
modeCOMBOmaskingclassic: MASK = thresholded edge pheromone. masking (Stage 2): MASK = sticky-latched, gap-closed, despeckled contour.
mask_thresholdFLOAT0.150.01–0.95classic mode only: threshold on the normalised edge map for the MASK output.
sticky_thresholdFLOAT0.200.05–0.6masking mode: latch a cell when its edge pheromone crosses this fraction of the field maximum.
freeze_afterINT00–20000masking mode: freeze (and clean) the mask after this many ticks. 0 = run all steps, then freeze.
no_decayBOOLEANfalsemasking mode: stop edge-pheromone evaporation entirely.
max_sideINT5120–4096Downsample the longest side to this for simulation (0 = full resolution). Outputs are resampled back.

Outputs (2)

NameTypeDescription
edge_mapIMAGE
maskMASK