upxo.meshing.gbconformant.d3v2p1.numba_smoothing module

numba kernels for tet dihedral smoothing.

star_trials(x0, slot, trials) evaluates every trial position of one node against the tets of its star: smallest and largest dihedral angle (degrees) and signed volume per (trial, tet), as d3v2p0.tet_smoothing._improve_node’s evaluate() does with dihedral_angles_xyz and _volumes, in one compiled loop. Import this module only after backend.numba_available() is True.

upxo.meshing.gbconformant.d3v2p1.numba_smoothing.star_trials(x0, slot, trials)[source]

(amin, amax, volume), each (len(trials), len(x0)): x0 (k, 4, 3) star tets, slot (k,) the node’s position in each tet, trials (B, 3).

upxo.meshing.gbconformant.d3v2p1.numba_smoothing.triangle_min_angles(x)

Smallest angle (degrees) of triangles x (N, 3, 3), as d3v2p0’s _triangle_min_angles.

upxo.meshing.gbconformant.d3v2p1.numba_smoothing.closest_on_segments(y, a, b)

Closest points from y (B, 3) to segments a-b (m, 3): (B, m, 3).

upxo.meshing.gbconformant.d3v2p1.numba_smoothing.closest_on_triangles(y, x)

Closest points from y (B, 3) to triangles x (m, 3, 3) and their distances: ((B, m, 3), (B, m)), as d3v2p0’s _closest_on_triangles_batch.