skeleton_junctions3d — 3D medial op

• Data kinds: voxel → voxel

• Call: import fullseye as fs; fs.ledger.skeleton_junctions3d(vol) (to call the implementation directly, import medial; medial.skeleton_junctions3d(vol); from the registry, ops3d.get("skeleton_junctions3d"))

Usage

Return the junctions of a 3-D skeleton (three or more skeleton voxels in the 26-neighbourhood) as a voxel mask.

Input that is not a skeleton (a blob with an interior) is thinned with skeletonize_vol before measuring. 3D version of the 2D junctions_skeleton. Used to turn blood vessels, porous media and network-like structures into graphs (node extraction). If you only want aggregated branch degrees, topology_signature returns them as a dict.

Caution (honest): the 26-neighbourhood degree can come out too high through diagonal adjacency near branches (a known property of discrete skeletons). When counting the *number* of branches, group this mask into connected components.

Procedure: _ensure_skeleton converts the input to bool, and if there is even 1 interior voxel whose 6-neighbourhood (face neighbours) is all foreground, it regards the input as "not a skeleton" and first applies skeletonize_vol (skimage Lee method). Then a convolution with a 3x3x3 kernel of all 1s (centre 0) (mode="constant", outside is 0) counts the skeleton voxels in each voxel's 26-neighbourhood (degree), and skel & (degree >= 3) is returned.

Returns: a bool array of the same shape as the input. All False if there is no foreground. Anything other than skeleton voxels is always False. Coordinates in (z, y, x) order are obtained with np.argwhere.

Validation (ValueError): input that is not 3-D, an empty array, or a float containing NaN/Inf. ImportError if thinning is needed in an environment without scikit-image.

Note: the interior check runs every time, even for input that is already a skeleton (for a thin skeleton the thinning is skipped). To count them, use the number of components of vol_label(mask, 26). Splitting into branches is skeleton_branches3d; endpoints are skeleton_endpoints3d.

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)

• medial_topology — py -3.11 examples_3d/medial_topology.py

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

voxel_to_mips · voxel_to_mesh · signed_distance_field · to_points · sobel3d · hessian3d · curvature_maps · edt_jfa

Same category (medial)

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


*Provenance: medial.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.