Skip to content

probe(probes): place trim neighbours through their own face (#2085) - #2136

Merged
DrunkOnJava merged 1 commit into
DrunkOnJava:research/2085-ring-joinfrom
shifatrHtH:codex/2085-own-neighbour-probe
Nov 22, 2026
Merged

DrunkOnJava merged 1 commit into
DrunkOnJava:research/2085-ring-joinfrom
shifatrHtH:codex/2085-own-neighbour-probe

Conversation

@shifatrHtH

Copy link
Copy Markdown
Contributor

Summary

Extend probe_2085_trim_breaks to measure a neighbouring trim loop using the evaluator for that face. The new rows distinguish an edge passing near a gap from a pair of stored endpoints that meet on the adjacent face. The existing piecenbr rows remain available for comparison.

Motivation

In #2085, the plane/cylinder neighbour search leaves some spline-side loop edges unread. The graph already holds the evaluated samples on both sides of each edge. Reusing the adjacent face's cached placement makes those samples comparable to the same-save Revit vertices.

Changes

  • Emit ownnbr for the preceding and following edges in the other face's loop. Each row gives polyline and endpoint distances to P and Q, plus the distance from the closest shared endpoint to the closest adjacent endpoint. Emit a reason when the needed face, loop, or placement cannot be read.
  • Document the fields and their interpretation in the dated format reconnaissance addendum.

Testing

  • tools/check-local.sh passed, including workspace Clippy, rustdoc, builds, the real-file/CLI/contract gate (315 checks), and the CLI examples.
  • Compared exact base 2f73e456 and this patch on the BIM4LCA Office Concrete As-Built RVT and Revit IFC (VTT, Arkkitehtitoimisto Huvila, Gravicon and Granlund, CC BY-SA 4.0). The two inputs passed the repository's pinned archive-entry checks. Removing the new row types leaves all 1,752 baseline rows byte-identical. The patch adds 228 readable rows across 73 census gaps, with 30 sides read through a parametric evaluator, and 32 unread rows for absent opposite faces. Both probes and the scorer exited cleanly.
  • The unchanged IFC scorer matches all 107 eligible occurrences to the census and scores 65 occurrences across 13 distinct gaps. Join each new row to the scorer by graph, face, loop and position. Of the 10 scored sides where a neighbour endpoint is within 1e-7 ft of its shared endpoint and one gap end, and Revit's raw IFC has a vertex at just one gap end, Revit keeps the neighbour's end on seven sides and the other end on three. The side counts refer to stored gaps. A single gap can contribute two sides.
  • On the private Family instances that stay boxes: expose symbol geometry and instance placement #2085 model, the patch preserves every prior probe row and reproduces the neighbouring spline coverage and results documented in the issue. IFC export witnesses and performance benchmarks are inapplicable to a diagnostic-only patch.

Public reproduction:

python3 tools/ci/fetch-bim4lca.py research/bim4lca-measure.tsv /tmp/rvt-office-check \
  ARK_NordicLCA_Office_Concrete_As-Built.rvt ARK_NordicLCA_Office_Concrete_As-Built_Revit.ifc
cargo run --profile ci -p rvt-probes --example probe_2085_trim_breaks -- \
  /tmp/rvt-office-check/ARK_NordicLCA_Office_Concrete_As-Built.rvt > office.txt
python3 tools/re/boundary_gaps_vs_ifc.py office.txt \
  /tmp/rvt-office-check/ARK_NordicLCA_Office_Concrete_As-Built_Revit.ifc --per-gap

Audit honesty

The dated addendum describes the probe and its public check. The new output is limited to the unpublished research example. The library, mesher, IFC exporter, and public API are unchanged. The observed neighbour contact is a diagnostic and the source of Revit's endpoint selection remains open.

Legal and contribution hygiene

This contribution is licensable under Apache-2.0. It is based on the public rvt-rs probe and its existing surface evaluators, observations of Revit saves and their corresponding IFC exports, and the public IFC representation. No Autodesk or ODA SDK source, leaked documentation, NDA material, decompiled internal implementation code, or copied or translated revit-ifc code was used. No fixture or private probe output is included.

Breaking changes

None. The research probe adds rows and preserves its existing output.

Related issues

Refs #2085.

…ava#2085)

Report stored endpoint contact using the cached evaluator for the neighbouring face. Preserve the existing plane and cylinder diagnostic for comparison.
@DrunkOnJava

Copy link
Copy Markdown
Owner

@shifatrHtH, thank you. I read the whole change and ran it here.

  • Built and run on the BIM4LCA office as built (Measure 44993741634, this head). It exits 0 and adds 228 ownnbr and 32 ownnbrunread rows. Every other row is byte-identical to the office's probe output of the same probe before the change, all 1,752 of them, as you found.
  • The code. The rows read only the placements the probe already caches, through each face's own evaluator. place_why maps every stored point of an edge, its two ends included, or places nothing, so taking a line's first and last point is safe.
  • Your public reading, reproduced. 3a94242a on research/2085-ring-join adds a scorer line for ownnbr, counted once per stored gap's side. On that run it gives the same 7 and 3: of the 10 sides where a neighbour's end joins the shared edge within 1e-7 ft and lies at one gap end, Revit keeps that end on 7 and the other on 3.
  • The declaration covers what CLEANROOM.md asks.

I am merging it into research/2085-ring-join.

@DrunkOnJava
DrunkOnJava merged commit bde05bd into DrunkOnJava:research/2085-ring-join Nov 22, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants