Deep Floor Plan Recognition Using a Multi-Task Network With Room-Boundary-Guided Attention

Zhiliang Zeng, Xianzhi Li, Ying Kin Yu, Chi-Wing Fu

Introduction

Automating the recognition of floor plans is a long-standing challenge in computer vision. Unlike natural images, floor plans are structured graphical notations where spatial relationships and boundaries define the identity of elements. Humans can intuitively distinguish a bedroom from a hallway by observing walls and doors, but machines often struggle with these non-pixel-independent relationships.

Traditional methods frequently rely on "Manhattan world" assumptions—expecting 90-degree angles and uniform wall thickness—which fail in modern, complex architectural designs. This paper proposes a deep multi-task neural network that leverages room-boundary information to guide room-type classification, effectively handling irregular geometries and curved walls.

Proposed Methodology

The core of the proposed approach is a multi-task network architecture designed to capture the structural hierarchy of floor plans. The network utilizes a shared VGG encoder to extract high-level features, which are then fed into two specialized decoding branches: one for room-boundary prediction (walls, doors, windows) and another for room-type prediction (kitchen, bedroom, balcony, etc.).

The overall network architecture features a shared VGG encoder branching into room-boundary and room-type prediction paths, linked by an attention mechanism.

Room-Boundary-Guided Attention

To prevent feature "bleeding" across walls, the authors introduce a Spatial Contextual Module. This module uses the features from the boundary branch to create an attention map for the room-type branch. By explicitly modeling boundaries, the network ensures that room classification is confined within the appropriate structural limits.

Direction-Aware Kernels

A key innovation is the use of direction-aware kernels within the spatial contexture module. These specialized convolutional filters scan in four primary directions (horizontal, vertical, and two diagonals) to identify boundaries. This allows the model to "scout" the extent of a room regardless of its orientation, enabling the recognition of non-rectangular and curved spaces that often stymie standard segmentation networks.

Experimental Setup and Datasets

The model was evaluated on two distinct datasets to test its robustness:

  1. R2V (Raster-to-Vector): Comprising 815 images, this dataset primarily features rectangular rooms with uniform wall thickness.
  2. R3D: A more complex set of 232 images characterized by irregular junctions, non-uniform wall thicknesses, and curved architectural elements.

Due to a lack of pre-existing pixel-wise labels for these specific tasks, the authors manually annotated these datasets to establish a high-quality ground-truth benchmark for the research community.

Results and Analysis

The multi-task network significantly outperformed both specialized floor plan tools and general-purpose semantic segmentation models like PSPNet and DeepLabV3+. On the R2V dataset, the model achieved a pixel accuracy of 89%. In the more challenging task of wall detection on the R3D dataset, the model reached an F-measure of 0.95, far exceeding the 0.68 achieved by standard edge-detection networks (RCF).

Qualitative results demonstrate the model's ability to accurately delineate room boundaries and classify types even in layouts with curved walls and complex junctions.

Qualitatively, the model produces clean, structured data suitable for automatic 3D reconstruction. It successfully handles "organic" architecture, such as the curved walls shown in Figure 1, which are typically problematic for Manhattan-constrained systems. The use of a cross-and-within-task weighted loss further ensures that rare elements like windows are accurately detected.

Conclusion

By integrating room-boundary detection and room-type classification into a single, mutually reinforcing framework, this research provides a robust solution for automated floor plan analysis. While the model occasionally struggles with winding corridors or large graphical icons (e.g., compasses), its ability to handle non-uniform geometry represents a significant advancement. Future work will focus on extracting text labels, recognizing furniture symbols, and parsing numerical dimensions directly from the source images.

Summary updated

BibTeX
@inproceedings{zeng2019deep,
  author = {Zhiliang Zeng and Xianzhi Li and Ying Kin Yu and Chi-Wing Fu},
  title = {{Deep Floor Plan Recognition Using a Multi-Task Network With Room-Boundary-Guided Attention}},
  booktitle = {IEEE/CVF International Conference on Computer Vision},
  year = {2019},
  doi = {10.1109/iccv.2019.00919},
}
Figure