upxo.meshing.gbconformant.d3v2p1.surface_angles module

Parallel surface-angle repair with the same result as d3v2p0.

Each pass works in rounds. A round evaluates the best operation of every pending triangle in parallel (d3v2p0’s candidate function and the same no-sharpening arithmetic) on the current state. The greedy loop then applies them worst-first, as d3v2p0 does, but defers a triangle whose evaluation has gone stale (a node it read was changed by an operation applied after it was made) to the next round instead of evaluating it again on the spot. Every applied operation was therefore evaluated on the exact current state and passes the same rules and the same verification as in d3v2p0; only the order differs, so the result is close to, not identical with, d3v2p0’s. It does not depend on the worker count.

upxo.meshing.gbconformant.d3v2p1.surface_angles.improve_surface_angles(surface, enabled=True, minimum_angle=30.0, max_passes=10, max_deviation=None, minimum_facet_angle=0.1, frozen_grain_ids=(), flips=True, relocation=True, collapses=True, max_normal_change=60.0, wedge_limit=None, n_workers=None, max_rounds=8, backend='auto', progress=None, track_history=False)[source]

d3v2p0.surface_angles.improve_surface_angles with parallel candidate evaluation in rounds. backend / n_workers: see d3v2p1.backend (None = automatic); the result does not depend on n_workers. max_rounds: evaluation rounds per pass; triangles still stale after it are worked on again in the next pass.

backend=’numba’ (also UPXO_BACKEND=numba) runs the compiled tier instead, d3v2p1.numba_surface_angles: d3v2p0’s order of work, so its result is d3v2p0’s (coordinates to the last digits of a float) and not the rounds’ above; max_rounds does not apply to it. If numba is missing or the kernels cannot compile here, the parallel / numpy tier runs and the report says why. ‘auto’ never selects the compiled tier.