Skip to content

Implement Attached Neighbour Detection #13

Description

@jravani

Overview

No neighbour detection exists in City2TABULA.
This sub-issue introduces a method to detect which buildings are attached to each other based on their footprints or envelopes.

Attached neighbours are buildings that:

  • Touch or overlap in 2D
  • Are separated only by very small geometric gaps (tolerance required)

This is a prerequisite for Party Wall Detection.


Requirements

  1. Compute building footprints or envelopes.
  2. Detect potential neighbours using spatial operations:
    • ST_Intersects(footprint, footprint)
    • ST_Touches
    • ST_DWithin(footprint, footprint, tolerance)
  3. Store neighbour relationships in a table or directly in building attributes.
  4. Ensure the method works across datasets with varying geometry quality.

Output

For each building:

  • neighbour_ids (array or mapping table)
  • Boolean has_attached_neighbours

These results will be used by Sub-Issue B.


Notes

  • Tolerance is required due to minor dataset gaps.
  • 3DBAG has cleaner geometry; DE/AT may need relaxed thresholds.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Fields

No fields configured for Feature.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions