Graph Helpers
core_sg.edgesBuilds vectorized kNN edge arrays and merges MST edges into metric edges.
core_sg.knnExtracts nearest-neighbor arrays from a precomputed distance matrix.
core_sg.reweightSorts Core-SG edge arrays and applies mutual-reachability reweighting.
core_sg.mst_kruskalProvides Kruskal MST extraction with a Cython backend and Python fallback.
Key helper functions include build_knng_vectors,
add_mst_edges_to_metric_edges, knn_from_precomputed,
reweight_core_sg_mutual_reachability, sort_core_sg, and
kruskal_mst.