Skip to content

_spd_sanitise: all-NaN eigenvalues on a rank propagate NaN instead of the SPD fallback (mmpde live path) #352

Description

@lmoresi

Found by the Copilot pass over Wave D PR #345 (2026-07-08); TODO(BUG) marker at src/underworld3/meshing/smoothing/mmpde.py (commit 300bba4). Confirmed by numpy probe; pre-existing (bit-identical at base, code from the #259 SPD-floor era).

When every eigenvalue on a rank is NaN/inf, np.nanmax(w) is non-finite, making the floor non-finite and the projection emit NaNs instead of a usable SPD fallback — defeating the sanitiser's purpose exactly when it is most needed. This is the surviving mmpde mover's path (unlike the retired-mover findings), so it deserves a real numerics fix: guard wmax to a finite value (e.g. fall back to identity metric scaled by a mesh-derived length) when no finite eigenvalue exists.

Related: #259 (original SPD-floor fix), #346 (retired-mover collective hazard — different path).

Underworld development team with AI support from Claude Code

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions