Abstract
We introduce a novel bilateral reference framework (BiRefNet) for high-resolution dichotomous image segmentation (DIS). It comprises two essential components: the localization module (LM) and the reconstruction module (RM) with our proposed bilateral reference (BiRef). The LM aids in object localization using global semantic information. Within the RM, we utilize BiRef for the reconstruction process, where hierarchical patches of images provide the source reference and gradient maps serve as the target reference. These components collaborate to generate the final predicted maps. We also introduce auxiliary gradient supervision to enhance focus on regions with finer details. Furthermore, we outline practical training strategies tailored for DIS to improve map quality and training process. To validate the general applicability of our approach, we conduct extensive experiments on four tasks to evince that BiRefNet exhibits remarkable performance, outperforming task-specific cutting-edge methods across all benchmarks.
Introduction
Dichotomous Image Segmentation (DIS) is a specialized sub-field of computer vision focused on the precise extraction of objects with extremely intricate details, such as bicycle spokes, thin tree branches, or ornate architectural elements. Traditional segmentation methods often struggle with the trade-off between computational efficiency and the preservation of fine-grained details. Resizing high-resolution (HR) images to lower resolutions leads to the loss of vital structural information, while processing full HR images is often prohibitive.
The BiRefNet Architecture
To address these challenges, we propose BiRefNet, a framework that decouples the segmentation task into localization and reconstruction.
Localization Module (LM)
The LM utilizes a Swin Transformer backbone to extract hierarchical features. Its primary role is to generate a coarse, low-resolution prediction by focusing on global semantic information—essentially identifying "where" the object is located within the frame.
Reconstruction Module (RM) and Bilateral Reference
The core innovation of BiRefNet lies in the RM, which refines the coarse map using a Bilateral Reference (BiRef) strategy:
- Inward Reference (InRef): To maintain spatial resolution without excessive memory costs, the model adaptively crops the original HR image into patches. These patches are fed directly into the decoder stages, providing "lossless" detail features.
- Outward Reference (OutRef): The model generates and supervises gradient maps. Because gradients naturally highlight edges and fine structures, this "outward" guidance forces the network to focus on the most difficult, slender parts of an object.
Training Strategies
To ensure effective convergence and high-quality output, we employ two specific strategies:
- Multi-Stage Supervision (MSS): This approach significantly accelerates training, achieving competitive results in roughly 30% of the time required by standard long-term training.
- Region-Level Loss Fine-Tuning (RLFT): This helps the model produce sharper binary masks by focusing on local region consistency.
Key Results and Evaluation
BiRefNet was evaluated across several benchmarks, including DIS5K, High-Resolution Salient Object Detection (HRSOD), and Concealed Object Detection (COD).
Quantitative Performance
The model consistently outperformed state-of-the-art (SOTA) methods like IS-Net and UDUN. On the DIS5K benchmark, BiRefNet achieved a 6.8% improvement in the structure measure ($S_m$). It also demonstrated significant gains of 2.0% on HRSOD and 5.6% on COD tasks.
Qualitative Analysis
Visual comparisons highlight BiRefNet's superior ability to segment "hair-level" details. While competing models often blur or miss internal gaps in complex structures, BiRefNet maintains high fidelity to the ground truth.
Conclusion
BiRefNet represents a significant advancement in high-resolution image segmentation. By combining global semantic localization with patch-based and gradient-guided reconstruction, it effectively captures the intricate details necessary for DIS. The framework's success across salient, concealed, and dichotomous object detection tasks underscores its general applicability and robustness.
Summary updated