Repository navigation
fix(elements): write the storey of a project with one Level - #1086
Merged
Merged
Conversation
recovered_levels_are_a_storey_set asked for at least two Levels, so R2025 01_Walls (one Level, 'Level 1' at 0 ft, ElementId 1951, decoded whole by probe_re51_level_names in Measure 40934704557) exported its five walls on no storey while Revit's export has them on Level 1. The floor was arbitrary: the one-block-per-Level check is what keeps a partial recovery out. One Level is now accepted only when scan_partition_level_ids, the broader id scan, finds no other Level either.
Einhoven (Revit 2023) decodes one Level while its ArcWalls stand at two or more base elevations, which RE-15's storeys from wall bases show; the corpus test arcwall_decoder_yields_ifcwall_on_einhoven caught the lone Level replacing them. With no Revit export of Einhoven to say which is right, the one-Level rule is narrowed to the releases its oracle, R2025 01_Walls, is on.
Owner
Author
|
Measure run 40942112911 (head 4f3c265 against main af50068, every model and scorer): 89 models, two IFCs moved, r2025-00_Blank and r2025-01_Walls. Every other ifc.sha256 is unchanged.
|
DrunkOnJava
enabled auto-merge (squash)
October 29, 2026 20:18
3 tasks done
DrunkOnJava
added a commit
that referenced
this pull request
Oct 29, 2026
…FC 26.1 writes (#1097) (RE-263) (#1098) ## Summary Closes #1097. Revit's exporter writes `Pset_BuildingCommon.NumberOfStoreys` by two rules: up to IFC 26.0 the number of storeys that contain an element, from IFC 26.1 the number of storeys (revit-ifc `NumberOfStoreysCalculator`, changed in the "IFC 26.1 for Revit 2026" commit ef15008e2e). rvt-rs writes the number of storeys, IFC4's definition. The W7 census now counts the older value apart instead of as different. ## Changes - `tools/re/psets_vs_ifc.py`: reads the reference export's exporter version from its `FILE_NAME` originating system, its storeys and the storeys some element is contained in; counts `NumberOfStoreys` apart, on its own line, where the exporter is older than 26.1, not every storey contains an element, and Revit's value is the number that do. An export naming no exporter is scored as before. - `reports/element-framing/RE-263-number-of-storeys.md`: the measured table (24 of 24 named pre-26.1 exports, plus BIMcollab, follow the older rule; 5 of 5 from 26.1 the newer). - RE-253: its artefacts line said both held-out ribeiro exports were Revit 25.4's; `modelo_bim`'s header names Revit 26.2 (IFC 26.1.0.23). - `changelog.d/research/number-of-storeys.md`. ## Testing Unit tests are banned in this repository: do not add them. - [x] Verified on real files: Measure run 40948455973 (main ed337dd with this branch's census, r2025 and nordic): the RE-263 line counts the property apart on 21 R2025 models (the 20 that differ, and 00_Blank, which main does not yet give its storey, #1086) and nowhere else. RE1's four and the office's two stay equal; 01_Walls stays scored. - [x] `python3 tools/ci/api-doc-ids.py` and `python3 tools/release/changelog.py check` pass. No export changes. ## Legal and contribution hygiene - [x] revit-ifc (CLEANROOM.md source 5) read and cited by file, class and commit; nothing copied. Held-out models: counts only.
3 tasks
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
A project with exactly one Level now exports its storey. recovered_levels_are_a_storey_set required at least two Levels; it now requires at least one, and scan_partition_levels keeps a single Level only when scan_partition_level_ids (the broader Level-id scan) also finds exactly one.
Motivation
R2025 01_Walls (puzzbobb's Apache-2.0 models, research/r2025-models.tsv) exports its five walls (2787, 2788, 2789, 2790, 2892) on no storey, while Revit's export of it has IfcBuildingStorey 'Level 1' containing all five. Measure run 40934704557 (probe_re51_level_names, main af50068) shows its one Level decodes whole: 'Level 1', ElementId 1951, 0.0 ft, and the same on 00_Blank, while the four-Level control 02_1Slope recovers all four. The two-Level floor was arbitrary: the one-block-per-Level check is what keeps a partial recovery out, and the broader id scan now covers the one-Level case.
Changes
Testing
Unit tests are banned in this repository: do not add them.
Audit-honesty checklist
Legal and contribution hygiene
Breaking changes
None.
Related issues
None open; found by the 2026-10-29 identity sweep. Related: #1097.