tessl install tessl/pypi-numpy-stl@3.2.0Library to make reading, writing and modifying both binary and ascii STL files easy.
Agent Success
Agent success rate when using this tile
85%
Improvement
Agent success rate improvement when using this tile compared to baseline
1.39x
Baseline
Agent success rate without this tile
61%
Implement a utility that loads an STL mesh, optionally drops degenerate facets, forces recalculation of geometry-derived data, and returns a structured summary.
@generates
from typing import Dict, List, Sequence
def mesh_report(path: str, *, remove_degenerate: bool = True) -> Dict[str, object]:
"""
Load an STL mesh file, refresh geometry-derived properties, and return a summary.
Returns a dictionary with:
- "triangles": int count of retained facets after optional filtering
- "unit_normals": sequence of 3-float unit normals aligned with the refreshed geometry
- "areas": sequence of facet areas ordered consistently with normals
- "centroids": sequence of facet centroids ordered consistently with normals
- "bounds": {"min": [x, y, z], "max": [x, y, z]} derived from refreshed vertices
"""
...Provides mesh loading, geometry recalculation, and unit normal helpers.