vol_nearest_seed_vector — 3D medial op

• Data kinds: voxel → flow_dense

• Call: import fullseye as fs; fs.ledger.vol_nearest_seed_vector(vol_binary, spacing=None) (to call the implementation directly, import volops; volops.vol_nearest_seed_vector(vol_binary, spacing=None); from the registry, ops3d.get("vol_nearest_seed_vector"))

Usage

Displacement vector from each voxel to the nearest seed voxel (3, D, H, W) (flow_dense, components dz, dy, dx [voxel]).

seed = non-zero voxel (binarised with > 0.5). 0 on the seeds. vol_distance_transform returns only the distance value, and "which voxel is nearest" is lost — the radius from the skeleton (surface → skeleton displacement), the wall thickness to the membrane, the ESDF gradient and the Voronoi partition of labels all need this direction (2026-09-21, a hole in the connectome foundation). If spacing (sz, sy, sx) is given, the nearest-neighbour decision uses physical distance (the returned displacement stays in voxel units — |v * spacing| is the physical distance). Exact solution: the linear-time EDT of Maurer, Qi & Raghavan (IEEE TPAMI 2003) (scipy.ndimage.distance_transform_edt(return_indices=True)). When several seeds are equally near, 1 is picked in that implementation's order (do not attach any meaning to the order). If there is not even 1 seed, ValueError (every voxel is infinitely far — it does not silently return 0).

>>> v = np.zeros((5, 5, 5)); v[2, 2, 0] = 1

>>> d = vol_nearest_seed_vector(v); d.shape, tuple(d[:, 2, 2, 4])

((3, 5, 5, 5), (0.0, 0.0, -4.0))

References (sample data, literature)

• Sample-data catalog (download URLs / licences) — 2-D uses skimage.data (BSD/public domain) plus synthetic images; 3-D lists download URLs for real data sources (Stanford, PDS, …).

• Operator provenance and references — the sources of the research/methods this op family came from.

Runnable examples (verified samples that actually call this op)

• nearest_seed_partition — py -3.11 examples_3d/nearest_seed_partition.py

Ops the type connects to (they accept flow_dense as input)

fuse_to_voxel

Same category (medial)

distance_ridge · skeletonize_vol · medial_axis_points · topology_signature · medial_match · skeleton_junctions3d · skeleton_endpoints3d · skeleton_prune3d


*Provenance: volops.py — 3D operator registry. This per-op note is generated by tools/opdocs.py md (do not hand-edit).*

© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.