Repository navigation
feat(re): the mesh body scorer reads a round section's volume against Revit's inscribed end faces and the faces its export writes twice (#1658) (RE-397) - #1662
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
mesh_bodies_vs_ifc.pyreads a body whose volume is outside 1% of Revit's shell by shell (tools/re/volume_readings.py), so a difference that is Revit's way of writing a body is told from one that is wrong: a round section drawn as a polygon inscribed in rvt-rs's circle, and a body written with every face twice. Scorer only: no export moves, the class table is unchanged, and ashell readings:line andreadingrows follow it.Motivation
#1658. RE-397 section 5.2 found that Revit's export draws a round section as an inscribed polygon with few corners, which the volume bar reads as a difference (a hexagon is 1.1989 in volume), and a row pre-registered on #1636 was missed for that reason alone. Reading the first Measure of this reading, the roofs, slabs and ramp flights that read exactly 0.5000 turned out to be another way Revit's export differs: it writes them with every face twice, in the same winding, so the mesh's volume is twice the body's.
Changes
tools/re/volume_readings.py(new): shells of a body, a cap (coplanar triangles joined through shared edges with one closed boundary loop), rvt-rs's circle and Revit's inscribed polygon, Revit's repeated triangles counted once, the reading of a pair of shells (equal,doubled,explained,other) and of a body. Numpy only.tools/re/mesh_bodies_vs_ifc.py:read_shellsprints theshell readings:line and thereadingrows (the first 25other, the first 5 of each other kind) after the outliers; a file with no outlier prints nothing new.tools/ci/scrub-holdout-results.sh: lets the oneshell readings:count line through for the models without a licence to redistribute, nothing else of the block (areadingrow names a Tag and a type).changelog.d/research/1658-shell-readings.md, and RE-397's report section 5.3 with the railings re-read beside the row as registered.The reading, fixed before the runs (rows on #1658)
A shell pair is
equalwithin 0.5% in volume. Otherwise it isexplainedwhen every end face of rvt-rs's that is a circle (at least 12 vertices within 0.001 ft of one radius) has a cap in Revit's inscribed in it (parallel, none beyond the radius plus 0.001 ft, at least 3 corners on the circle that surround its centre, the polygon through them the cap's area within 0.5%, every other vertex on an edge), the circles' area ratios agree within 0.5%, and the shell's volume ratio is within 2% of that ratio. It isdoubledwhen its volume is rvt-rs's within 0.5% once Revit's repeated triangles count once, and every vertex of each is within 0.01 ft of the other's surface (a whole body is read so when its shells do not pair). Everything else, and every shell with no partner, isother; rvt-rs's own triangles are never dropped.Testing
Unit tests are banned here and none is added. Measured on Revit's own exports (BIM4LCA office and housing, CC BY-SA 4.0, byte-range reads), with the rows registered before each run:
a5f4a5b4): the housing timber's every outlying railing isexplained, noneotherexplained; the 2otherare the roofKA-1and the doorUO-1)KAI-3railings areexplainedexplainedbody is a round part with inscribed end facesKA-1andUO-1areotherin the timber file as in the concrete oneVK-2is not an outlier in the timber file: my registration was wrong that it is)6d498b8b, the pre-filter lifted, the faces Revit's export holds twice read): the office's twoKAI-3railings areexplaineddoubledVK-2andKA-1,VK-1.pelti; the office's ramp flights 1440596, 1385462, 1385641, 1385926 and 1387294 and the roofKA-2(the 12 models; 8 to 40 triangles of Revit's repeat another per body)other: the housing's ramp flight 1347699 (0.4907, a vertex 3.2 ft away), the doorsUO-1,O-7,UO-3Not registered, found: the two small
KAI-5railings of the office (0.980) areexplainedthe other way round (14 or 15 shells at 0.9643, the end faces' area ratio: rvt-rs's circles have the fewer segments), so RE-397's "not located" is located; and the wallsVS-2,VS-3,VS-11of the office at permit and theIfcGeographicElementtrees of the terrain files readotherand are not touched here.The scrub was run on a copy of the office permit's scorer file with
RUNNER_TEMPset: it keeps the class rows and the oneshell readings:line (23 lines) and drops everyreadingrow.Not measured
holdout=truewas made; the scrub was checked on a public file as above.other, and a body readdoubledis held to the vertex bar of 0.01 ft but not to its shape beyond it.Reproduce
gh workflow run measure.yml --ref feat/round-section-volumes -f ref=5dd1277dcb96375ef54ceb6bed152a36fcb3eb4b -f base=none \ -f nordic=true -f models="nordic-*" -f scorers=mesh_bodies_vs_ifc(
--refnames the branch for the scorers; use its commit6d498b8bto read the second run, the code ismainat5dd1277d.) Theshell readings:line and thereadingrows are in each model'smesh_bodies_vs_ifc.txt.Audit-honesty checklist
changelog.d/research/docs/format-reconnaissance.mdentryLegal and contribution hygiene
Breaking changes
None. A scorer file gains lines after the class table.
Closes #1658