Abstract
Instance segmentation often suffers from coarse boundaries due to the loss of fine-grained details during feature downsampling and fixed-grid pooling (e.g., RoIAlign). This paper introduces RefineMask, a multi-stage framework designed to iteratively refine object masks by integrating high-resolution features from the backbone. By employing a Semantic Fusion Module (SFM) and a novel Boundary-Aware Refinement (BAR) module, RefineMask achieves significant improvements in mask quality with minimal computational overhead. Experimental results on COCO, LVIS, and Cityscapes demonstrate gains of up to 3.8 AP over Mask R-CNN, outperforming more complex state-of-the-art models.
Introduction
In computer vision, instance segmentation requires not just detecting an object, but outlining its exact pixels. Most modern systems use a two-stage approach like Mask R-CNN: first, they identify a bounding box, and then they crop and resize the features inside that box to predict a mask.
A major bottleneck in this process is coarseness. To save memory, systems downsample images into feature maps, and the RoIAlign process squashes features into a tiny fixed grid (often 14x14 or 28x28 pixels). For large objects, this results in the loss of fine-grained details—thin structures like chair legs or fingers become blobs, and sharp edges become rounded. RefineMask addresses this by re-introducing high-fidelity features into a multi-stage refinement process.
Methodology
RefineMask introduces a "refine-as-you-go" strategy to recover lost details. The architecture consists of three primary novel components integrated into a multi-stage pipeline.
Multi-Stage Mask Head and SFM
Instead of predicting a mask in one shot, RefineMask doubles the resolution at each step (e.g., 14x14 $\rightarrow$ 28x28 $\rightarrow$ 56x56 $\rightarrow$ 112x112). At every stage, the Semantic Fusion Module (SFM) fuses four information sources: current instance features, the mask from the previous stage, global semantic features (from the backbone's high-resolution P2 layer), and a global semantic mask. This selective injection of high-resolution features allows the model to "refine" rather than "hallucinate" details.
Boundary-Aware Refinement (BAR)
To maintain efficiency, the authors observed that interior pixels are easy to predict; errors primarily occur at the edges. The Boundary-Aware Refinement (BAR) module forces the model to focus its learning and computation specifically on pixels near the predicted boundaries in the later, high-resolution stages.
Experiments and Results
The authors evaluated RefineMask on three industry-standard benchmarks: COCO, LVIS (which features high-quality mask annotations), and Cityscapes (focused on urban street scenes).
Key Results
- Accuracy Gains: RefineMask consistently outperformed the Mask R-CNN baseline, achieving gains of +2.6 AP on COCO, +3.4 AP on LVIS, and +3.8 AP on Cityscapes.
- LVIS Performance: A single-model version of RefineMask outperformed the winner of the LVIS Challenge 2020 by 1.3 points.
- Efficiency: Despite the extra stages, RefineMask is quite fast. Using a ResNet-50 backbone, it runs at 11.4 FPS, which is nearly 3x faster than the high-performing Hybrid Task Cascade (HTC) model (4.4 FPS) while maintaining similar or better accuracy.
- Visual Quality: Qualitative results show the model successfully segmenting difficult thin structures, such as the legs of a horse or airplane tails, which previous models typically over-smoothed.
Conclusion
RefineMask demonstrates that high-quality instance segmentation is achievable by iteratively fusing fine-grained features and specializing in boundary refinement. While it remains dependent on the initial quality of the bounding box detector, its efficiency and accuracy make it a strong candidate for high-fidelity computer vision tasks. Future work may involve integrating these boundary-aware strategies into one-stage, anchor-free detectors to enable high-quality real-time segmentation.
Summary updated