Sparse Refinement for Efficient High-Resolution Semantic Segmentation

Zhijian Liu, Zhuoyang Zhang, Samir Khaki, Shang Yang, Haotian Tang, Chenfeng Xu, Kurt Keutzer, Song Han

Introduction

Semantic segmentation—the process of assigning a categorical label to every pixel in an image—is a cornerstone of modern computer vision, particularly for safety-critical applications like autonomous driving and medical imaging. To accurately detect small or distant objects, such as traffic signs or thin poles, models typically require high-resolution input (often 2 megapixels or more). However, the computational cost of processing these images scales aggressively with resolution, creating a significant bottleneck for real-time deployment.

While downsampling images is a common strategy to reduce latency, it often results in "blurry" object boundaries and the complete loss of fine-grained details. Existing refinement techniques that attempt to recover this detail often rely on dense patches or complex upsampling layers that still incur high GPU costs. This paper introduces SparseRefine, a novel "dense+sparse" framework designed to maintain megapixel-level detail without the associated computational tax.

The SparseRefine Framework

SparseRefine is designed as a modular, three-stage "add-on" pipeline that can be integrated with virtually any existing segmentation architecture, whether based on Convolutional Neural Networks (CNNs) or Transformers. The framework operates on the principle that high-resolution processing is only necessary for a small fraction of the image.

1. Dense Low-Resolution Prediction

The process begins by downsampling the input image (e.g., to 1/2 resolution). A standard, off-the-shelf segmentation model performs initial inference on this low-resolution version to generate a coarse prediction map. This stage captures the global context and the bulk of the scene's structure at a fraction of the cost of full-resolution inference.

2. Entropy-Based Pixel Selection

Rather than refining the entire image, SparseRefine identifies specific areas of uncertainty. The system calculates the Shannon entropy of the coarse predictions; high entropy typically correlates with object boundaries or small, ambiguous objects. The Entropy Selector identifies a sparse set of "troublesome" pixels—typically only about 10% of the total image—that require higher-resolution attention.

3. Sparse High-Resolution Refinement

The refinement stage focuses exclusively on the selected pixels:

  • Sparse Feature Extractor: Utilizing a modified MinkowskiUNet, the model extracts high-resolution features only for the identified sparse set. By using sparse convolutions, the system avoids wasting computational cycles on the 90% of pixels that are already correctly classified.
  • Gated Ensembler: A lightweight module intelligently fuses the initial coarse predictions with the new sparse high-resolution features to produce the final, refined output.

Experimental Evaluation

The researchers evaluated SparseRefine across several diverse datasets to demonstrate its generalizability, including Cityscapes and BDD100K (urban driving), Pascal VOC (object segmentation), DeepGlobe (satellite imagery), and ISIC (medical imaging).

Performance and Efficiency

The quantitative results demonstrate significant efficiency gains with negligible impact on accuracy:

  • Speedups: SparseRefine achieved a 3.7× speedup when paired with SegFormer-B5 and between 1.5× and 2.1× speedups for HRNet and Mask2Former architectures.
  • Accuracy: On the Cityscapes benchmark, SparseRefine matched or slightly exceeded the mean Intersection over Union (mIoU) of full-resolution models while significantly reducing the number of Multiply-Accumulate operations (MACs).
  • Qualitative Recovery: The framework successfully recovered thin structures and distant objects that were entirely absent in low-resolution baselines.

Discussion and Key Insights

The success of SparseRefine rests on the observation that errors are sparse. The difference between a low-resolution and high-resolution prediction is not uniform; it is concentrated in tiny fractions of the image. By fixing just that 10%, the model captures nearly all the benefits of high-resolution processing.

Furthermore, the authors found that simple Shannon entropy is a remarkably powerful signal for identifying these errors, outperforming more complex learnable selectors. Because SparseRefine treats refinement as a sparse point-cloud problem from the outset, it can leverage optimized libraries like TorchSparse++ to achieve real-world wall-clock speedups rather than just theoretical efficiency.

Limitations

Despite its advantages, SparseRefine has some limitations. It currently requires a two-stage training process where the refinement module is trained independently of the base model. Additionally, the system is dependent on the base model's initial output; if the low-resolution model is highly confident in an incorrect prediction (low entropy), the selector may miss the error. Finally, achieving these speedups requires hardware and software environments that support specialized sparse convolution kernels.

Conclusion

SparseRefine offers a compelling path forward for high-resolution vision tasks. By combining dense global context with sparse local refinement, it breaks the rigid link between image resolution and computational latency. The authors suggest that this "dense+sparse" paradigm could be extended beyond semantic segmentation to other high-resolution tasks such as depth estimation and optical flow.

Summary updated

BibTeX
@inproceedings{liu2024sparse,
  author = {Zhijian Liu and Zhuoyang Zhang and Samir Khaki and Shang Yang and Haotian Tang and Chenfeng Xu and Kurt Keutzer and Song Han},
  title = {{Sparse Refinement for Efficient High-Resolution Semantic Segmentation}},
  booktitle = {European Conference on Computer Vision},
  year = {2024},
  doi = {10.1007/978-3-031-72855-6\_7},
}
Figure