pointline-indoor-layout
Single-image indoor structure-line detector. From one RGB image it predicts dense heatmaps for the room structure โ floor-wall boundaries, ceiling-wall boundaries, wall-wall (vertical) edges and room corners โ both the visible parts and the full extent including parts hidden behind furniture. Furniture and object edges are intentionally ignored. A companion TiltNet estimates the camera's up direction (pitch/roll) and camera height from the same image, so detected floor lines can be lifted to 3D.
ํ๊ตญ์ด ์์ฝ โ ์ฌ์ง ํ ์ฅ์์ ์ค๋ด ๊ตฌ์กฐ์ (๋ฐ๋ฅ-๋ฒฝ ๊ฒฝ๊ณ, ์ฒ์ฅ-๋ฒฝ ๊ฒฝ๊ณ, ๋ฒฝ-๋ฒฝ ๋ชจ์๋ฆฌ)๊ณผ ๋ฐฉ ๋ชจ์๋ฆฌ๋ฅผ ์ฐพ๋ ๋ชจ๋ธ์ ๋๋ค. ๊ฐ๊ตฌ์ ๊ฐ๋ ค์ง ๋ถ๋ถ๊น์ง ์ด์ด์ ์์ธกํ๊ณ , ๊ฐ๊ตฌ ์ ์ ๋ฌด์ํฉ๋๋ค. ํจ๊ป ๋ค์ด ์๋ TiltNet์ ๊ฐ์ ์ฌ์ง์์ ์นด๋ฉ๋ผ ๊ธฐ์ธ๊ธฐ(์์ยท์ข์ฐ ๊ธฐ์ธ๊ธฐ)์ ์นด๋ฉ๋ผ ๋์ด๋ฅผ ์ถ์ ํฉ๋๋ค. ํ์ต ๋ฐ์ดํฐ๋ 100% ํฉ์ฑ ์ด๋ฏธ์ง(BlenderProc, Poly Haven CC0 ์์ฐ)์ด๊ณ , NVIDIA H100 4์ฅ์ผ๋ก ํ์ตํ์ต๋๋ค. ํฉ์ฑ ๊ฒ์ฆ์ ์์ ๊ตฌ์กฐ์ F1 0.94~0.99, ๊ธฐ์ธ๊ธฐ ์ค์ ์ค์ฐจ 0.50ยฐ์ ๋๋ค. ์ค์ฌ ์ฑ๋ฅ์ ์ ์ฑ ํ๊ฐ๋ง ํ์ต๋๋ค. ๋ผ์ด์ ์ค๋ Apache-2.0์ ๋๋ค.
Files
| File | Description |
|---|---|
layout.safetensors |
LayoutNet weights (32.9 M params, fp32) |
tilt.safetensors |
TiltNet weights (40.3 M params, fp32) |
model.py |
Model definitions + loaders |
inference.py |
Minimal example: image โ heatmaps (+ tilt/height) |
config.json |
Input size, normalization, channel order |
requirements.txt |
torch, timm, safetensors, opencv-python, numpy |
LICENSE, NOTICE.md |
Apache-2.0 license and third-party notices |
Quick start
pip install -r requirements.txt
python inference.py room.jpg --out out/ # heatmaps.npy, overlay.png, result.json
python inference.py room.jpg --out out/ --tilt --hfov 90
python inference.py room.jpg --out out/ --tilt --fx 500 --fy 500 --cx 320 --cy 240 # intrinsics of the input image
import torch
from model import load_layout, load_tilt
layout = load_layout("layout.safetensors", "cuda")
prob = torch.sigmoid(layout(x)) # x: (B,3,480,640) ImageNet-normalized RGB -> (B,8,240,320)
Model
LayoutNet โ ConvNeXt-Tiny encoder (timm convnext_tiny.fb_in22k initialization) + U-Net style decoder with a
stride-2 detail branch. Output: 8 heatmap logits at 1/2 input resolution.
| ch | name | meaning |
|---|---|---|
| 0 | floor_wall_full |
floor-wall boundary, full extent (incl. occluded) |
| 1 | ceiling_wall_full |
ceiling-wall boundary, full extent |
| 2 | wall_wall_full |
wall-wall vertical edge, full extent |
| 3 | floor_wall_vis |
floor-wall boundary, visible part only |
| 4 | ceiling_wall_vis |
ceiling-wall boundary, visible part only |
| 5 | wall_wall_vis |
wall-wall edge, visible part only |
| 6 | corner_full |
room corners, incl. occluded |
| 7 | corner_vis |
visible room corners |
TiltNet โ same encoder (initialized from LayoutNet) + a position-preserving head that also takes normalized
intrinsics [fx/W, fy/H, (cxโW/2)/W, (cyโH/2)/H]. Output: unit "up" vector in the OpenCV camera frame
(x right, y down, z forward) and log camera height in metres. Input must be 640ร480 (the script resizes).
Input: RGB, resized to 640ร480, ImageNet mean/std normalization.
Training
All training images are synthetic; no real photographs were used for training.
- Data: procedurally generated rooms, L-shaped rooms and corridors (walls, doors, baseboards, lights, 88 furniture
models) rendered with BlenderProc 2.8 / Blender 4.2, using Poly Haven CC0 HDRIs, textures and 3D models.
Ground truth = analytic layout lines with per-segment visibility.
- LayoutNet: 19,999 images (5,000 scenes ร 4 views).
- TiltNet: the above + 23,968 frames of synthetic camera sequences (robot height 0.2โ0.55 m and handheld 1.0โ1.7 m, with camera shake).
- Augmentation: horizontal flip, wide-angle radial lens distortion (applied consistently to the ground-truth line coordinates), exposure/gamma/contrast/saturation/white-balance jitter, blur, noise, JPEG.
- LayoutNet: 30,000 steps, AdamW (lr 4e-4 decoder / 1e-4 encoder, wd 0.05), batch 16 per GPU ร 4, bf16, CenterNet-style focal loss on Gaussian line/corner maps. โ2.2 h on 4ร NVIDIA H100 80GB.
- TiltNet: 15,000 steps, batch 32 per GPU ร 4, lr 3e-4, angular + log-height loss. โ50 min on 4ร H100.
- Training field of view: horizontal FOV โ 70ยฐโ110ยฐ.
Evaluation (synthetic, held-out scenes)
980 validation images from scenes not seen in training (400 rooms, 180 L-shaped rooms, 400 corridors). Heatmaps are thinned with line-perpendicular NMS and matched to ground truth within 2 px (lines) / 3 px (corners) at the 320ร240 output resolution.
| F1 | floor-wall | ceiling-wall | wall-wall | corners |
|---|---|---|---|---|
| visible | 0.983 | 0.989 | 0.976 | 0.978 |
| full (incl. occluded) | 0.940 | 0.965 | 0.938 | 0.925 |
By scene type (full extent, F1): corridor 0.980 / 0.985 / 0.977 / 0.972, room 0.915 / 0.957 / 0.916 / 0.899, L-shaped room 0.909 / 0.926 / 0.899 / 0.878 (floor-wall / ceiling-wall / wall-wall / corners).
TiltNet (2,132 validation images): tilt error median 0.50ยฐ, p80 1.17ยฐ, p95 2.78ยฐ (50.4% under 0.5ยฐ); camera height median relative error 6.6%.
Limitations
- Trained only on synthetic images. Real-world performance has been checked qualitatively only (indoor robot-camera video of corridors and offices): floor-wall and ceiling-wall boundaries transfer well, while wall-wall vertical edges and far walls of large open spaces are weaker. No quantitative real-image benchmark is reported.
- Assumes structured interiors with planar floor/walls/ceiling; outdoor scenes, curved walls and heavily cluttered spaces are out of distribution.
- Best results at 640ร480 with horizontal FOV โ 70ยฐโ110ยฐ; strong fisheye distortion should be undistorted first.
- Camera height is learned from synthetic room scale (0.2โ1.7 m cameras); treat it as an estimate.
- Not intended for safety-critical decisions without task-specific validation.
License
Code and weights: Apache-2.0. The encoder was initialized from ConvNeXt ImageNet-22k weights distributed via
timm (ConvNeXt: MIT, timm: Apache-2.0); see NOTICE.md for the full third-party notices. Training assets from
Poly Haven are CC0.
Acknowledgement
This work was supported by the 2026 High-Performance Computing Support Program (NIPA).
- Downloads last month
- 18