Add bulk UV sampler, TKHelix and MakeSphere (8.0.1.2)
- n3xd_ocp.sample.face_grid: a face's UV grid of points and outward normals in one GIL-free call, sampling exactly where np.linspace does so a caller's fitted surface does not move. - n3xd_ocp.helix: OCCT 8.0's TKHelix, which upstream does not bind at all. Takes Python lists rather than NCollection_Array1. Two things the header does not say, both found by probing: SetParameters wants N+1 diameters for N segments (one per boundary, so a taper interpolates), and the builder is right-hand only -- a negative pitch is error status 12, not a mirrored helix. - Bind BRepPrimAPI_MakeSphere and give inventory.py an EXTRA_SYMBOLS addendum for symbols no app source imports. assay's gen_flow_fixtures has been unrunnable since the 10C cutover for want of it; the gap was wider than --check, since sigdiff is inventory-driven too. Gates: 105 tests, 139/139 symbols, sigdiff clean, ASAN clean, wheel self-contained with no libGL/libX11 DT_NEEDED. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01HbTQ2HYWQwdtGmGJwypt6Z
This commit is contained in:
@@ -32,6 +32,15 @@ HERE = pathlib.Path(__file__).resolve().parent
|
||||
DEFAULT_INVENTORY = HERE.parent / "inventory.json"
|
||||
DEFAULT_APP = HERE.parent.parent / "app" / "backend"
|
||||
|
||||
#: Symbols no app source imports, so the scan below cannot see them, but which
|
||||
#: another consumer of this wheel needs. Hand-maintained: add the symbol and
|
||||
#: name who wants it, so a later reader can tell a real dependency from a
|
||||
#: leftover. Merged into the scan, so --emit keeps them.
|
||||
EXTRA_SYMBOLS: dict[str, dict[str, list[str]]] = {
|
||||
# assay/scripts/gen_flow_fixtures.py builds spheres for its CFD fixtures.
|
||||
"BRepPrimAPI": {"BRepPrimAPI_MakeSphere": []},
|
||||
}
|
||||
|
||||
|
||||
def scan(app_root: pathlib.Path) -> dict:
|
||||
"""Collect {module: {symbol: [attributes reached on it]}} from the app."""
|
||||
@@ -70,6 +79,10 @@ def scan(app_root: pathlib.Path) -> dict:
|
||||
mod, name = local[node.value.id]
|
||||
modules[mod][name].add(node.attr)
|
||||
|
||||
for mod, symbols in EXTRA_SYMBOLS.items():
|
||||
for name, attrs in symbols.items():
|
||||
modules[mod][name].update(attrs)
|
||||
|
||||
return {
|
||||
"app_root": str(app_root),
|
||||
"files_importing_ocp": files,
|
||||
|
||||
Reference in New Issue
Block a user