Introduction
Autonomous driving and augmented reality systems require a comprehensive understanding of their environment, spanning both 2D and 3D domains. While 2D tasks like semantic segmentation identify pixel-level categories, 3D tasks like object detection and depth estimation provide the spatial context necessary for navigation and interaction. Traditionally, these tasks are handled by separate models or complex multi-task learning (MTL) architectures with manually designed encoders and decoders.
This paper introduces MTCityscapes-3D, a new benchmark designed for simultaneous 2D and 3D scene understanding, and proposes TaskPrompter, a Transformer-based framework that unifies these tasks through learnable "task prompts."
Methodology: The TaskPrompter Framework
TaskPrompter redefines multi-tasking as a prompting problem, moving away from rigid architectural splits.
Spatial-Channel Task Prompts
The model utilizes learnable tokens, or "prompts," for each specific task: 3D Detection, Semantic Segmentation, and Depth Estimation. These prompts are embedded alongside standard image patches.
Unified Transformer Learning
Using a Swin-Base Transformer backbone, image patches and task prompts are processed together. The self-attention mechanism allows task prompts to attend to both image features and other task prompts. This architecture facilitates the simultaneous learning of task-generic features, task-specific features, and cross-task interactions at every layer.
To adapt to the Swin architecture's local window-based attention, task prompts are duplicated into each window to interact with local patches and then averaged to maintain global consistency.
Prediction Heads
The framework employs standard heads for segmentation and depth estimation. For the more complex 3D detection task, it integrates an FCOS-3D head to estimate 3D coordinates, rotations, and dimensions from the monocular input.
The MTCityscapes-3D Benchmark
The authors derived the MTCityscapes-3D Benchmark from the Cityscapes-3D dataset to address the scarcity of unified 2D-3D benchmarks. It consists of 2,975 training and 500 validation images. The benchmark focuses on three primary tasks:
- 3D Vehicle Detection (3Ddet): Predicting 3D bounding boxes, including pitch and roll angles.
- Semantic Segmentation (Semseg): 19-class pixel-level labeling.
- Monocular Depth Estimation (Depth): Predicting per-pixel distance.
Results and Key Insights
TaskPrompter demonstrates that joint learning across 2D and 3D domains provides significant performance gains. The attention-based prompting mechanism serves as a "shortcut" for task interaction, bypassing the need for complex, manually-engineered cross-talk modules.
As shown in the results table, TaskPrompter achieves state-of-the-art performance in 3D detection and depth estimation:
- 3D Detection: Reached 32.94 mDS, significantly higher than the single-task baseline of 26.90.
- Depth Estimation: Improved the RMSE to 6.78, compared to the previous SOTA of 6.92.
- Semantic Segmentation: Maintained a highly competitive 77.72 mIoU, nearly matching specialized single-task models while simultaneously performing two additional complex tasks.
The results suggest that 2D semantic context and depth information provide critical cues that bolster the accuracy of 3D object detection. Furthermore, the multi-task approach is more computationally efficient than deploying three independent specialized models.
Conclusion and Future Work
While TaskPrompter sets a new standard for monocular 2D-3D scene understanding, some constraints remain. High-resolution processing (1024x2048) required downsampling during training to manage memory. Additionally, the current Swin-based implementation does not yet utilize cross-task reweighting due to the complexity of extracting affinity maps from local window attention.
Future research may explore scaling TaskPrompter with larger Transformer backbones or extending the framework to a broader array of diverse tasks to further enhance autonomous perception systems.
Summary updated