extract_boundary_persistence
extract_boundary_persistence(tree, margin_pct=0.1)Identify points that persist as boundary across multiple tree depths.
Same concept as pca_tree.extract_boundary_persistence but for k-ary DYF trees. At each depth, points with centroid similarity below the margin_pct percentile threshold are tagged as boundary.
Parameters
| Name | Type | Description | Default |
|---|---|---|---|
| tree | DYF tree dict from build_dyf_tree(). | required | |
| margin_pct | Percentile threshold (0-1). | 0.1 |
Returns
| Name | Type | Description |
|---|---|---|
| dict with: boundary_depths: dict[int, list[int]] boundary_count: np.ndarray shape (n,) thresholds: dict[int, float] |