Repository navigation
v5.5.0
What's New
The per-class Building file now gives each building its own height, pitch and 3D flag, and the per-class Roof file no longer loses RSI in chunks where only Building Lifecycles carry it. Chunks made up mostly of vegetation and surface polygons now take a quarter or less of the memory and time in the per-class step.
Bug Fixes
- The per-class Building file's 3D columns now belong to the right building.
- Scope: only the per-class Building file (
building.csv,building_features.parquetand the chunkbuilding_*files), and in it onlyhas_3d_attributes,height_*,num_storeys_*_confidence,pitch_degreesandground_height_*. The per-property rollup (primary_building_*,primary_roof_*), the per-class Roof file and the Building file's other columns, includingprimary_child_roof_*, were not affected. - Before: when a chunk's Building rows were not its first rows, most buildings got blank values in these columns and a few got another building's values. When
aoi_idwas the frame's index, the columns were left out of the file. - Now: each building's values are its own.
- Per-class Building files written by nmaipy 4.3.0 to 5.4.0 may be affected. Re-export them if you use these columns.
- Scope: only the per-class Building file (
- The per-class Roof file no longer loses RSI when no roof in a chunk has RSI of its own.
- Before: when structural damage is present, the Feature API puts
roofSpotlightIndexon the Building Lifecycle instead of the roof, and nmaipy resolves each roof's RSI from there. The Roof file wrote that RSI only into columns that a roof's own RSI had created. So in a chunk where no roof had RSI of its own, such as a small export of damaged buildings, the Roof file had noroof_spotlight_indexcolumns at all. Chunks with at least one roof with its own RSI were not affected, and neither were the rollup, the Building file and the Building Lifecycle file. - Now: the RSI columns are added when no roof created them.
- Per-class Roof files written by nmaipy 4.6.0 to 5.4.0 may be affected.
- Before: when structural damage is present, the Feature API puts
Performance
- The per-class step no longer unnecessarily processes every vegetation and surface row in a chunk.
- Before: the chunk-level parent lookup held a row for every feature, and every non-roof row was grouped and re-projected as a candidate roof child. On a chunk made up mostly of classes that get no per-class file, this peaked at about 7 GB per 1M feature rows. The rollup built the same full lookup again.
- Now: the lookup holds only the rows nmaipy reads from it, and children are grouped only for AOIs that have a roof. On a real chunk that is 99.5% vegetation and surfaces, the per-class step peaks at 0.4–1.7 GB per 1M rows instead of 6.7–7.1 GB, and takes 7 s instead of 26 s. Its outputs are byte-identical.
- With pandas 2.x and roof age off, the raw features frame is also freed after its last use, about 0.7 GB per 1M rows sooner.
Deprecations
- Deprecated, to be removed in 6.0:
nmaipy.parcels.build_parent_lookup_by_aoi. It was internal plumbing, and nmaipy no longer calls it. It still returns every row, as before, and now emits aDeprecationWarning.
Notes
- Dependencies are unchanged.