meshing.features.classify_feature_cells

meshing.features.classify_feature_cells(
    hermite,
    incidence,
    *,
    crease_threshold=0.25,
    corner_threshold=0.25,
)

Classify active cells as face, crease, or corner from normal spread.

For each cell, the incident Hermite unit normals are centered about their mean and the singular values of the count-normalized spread measure how many independent directions they fan across. The leading singular value is compared against crease_threshold and the second against corner_threshold. For two normal clusters at angle around their mean the leading singular value equals sin(α), so it is monotonic in crease sharpness all the way to opposed normals, and the default of 0.25 fires at a normal fan of roughly 29 degrees while a smooth surface at cell size h and curvature radius r stays near h / (2 r).

The singular values and measures are differentiable JAX values; exactly degenerate directions (flat geometry) get a zero subgradient. The class labels are concrete and frozen per extraction, like the edge set.