Diffusion-based Image Translation with Label Guidance for Domain Adaptive Semantic Segmentation

Duo Peng, Ping Hu, Qiuhong Ke, Jun LiuICCV 2023

Abstract

Translating images from a source domain to a target domain for learning target models is one of the most common strategies in domain adaptive semantic segmentation (DASS). However, existing methods still struggle to preserve semantically-consistent local details between the original and translated images. In this work, we present an innovative approach that addresses this challenge by using source-domain labels as explicit guidance during image translation. Concretely, we formulate cross-domain image translation as a denoising diffusion process and utilize a novel Semantic Gradient Guidance (SGG) method to constrain the translation process, conditioning it on the pixel-wise source labels. Additionally, a Progressive Translation Learning (PTL) strategy is devised to enable the SGG method to work reliably across domains with large gaps. Extensive experiments demonstrate the superiority of our approach over state-of-the-art methods.

Introduction

Semantic segmentation is a critical task in computer vision, yet its reliance on large-scale, manually labeled datasets presents a significant bottleneck. Domain Adaptive Semantic Segmentation (DASS) offers a solution by leveraging synthetic data (e.g., GTA5, SYNTHIA) where labels are automatically generated. However, a significant "domain gap" exists between synthetic and real-world data, often leading to poor model generalization.

Traditional DASS methods frequently employ Generative Adversarial Networks (GANs) to translate source images into the target domain style. Unfortunately, GANs are prone to instability and often fail to maintain semantic consistency, leading to "hallucinated" objects or the loss of fine-grained details during translation. As shown in Figure 1, existing methods may misinterpret small objects like traffic lights, whereas the proposed method maintains high fidelity to the source labels by using them as explicit guidance.

Comparison of the proposed architecture and qualitative results against existing methods.

Methodology

The proposed framework introduces a diffusion-based approach to image translation, enhanced by label-driven guidance and a progressive learning strategy.

Diffusion-based Baseline

Instead of GANs, this method utilizes Denoising Diffusion Probabilistic Models (DDPMs). The process involves a forward diffusion phase where noise is added to a source image $x_0$ over $n$ steps, followed by a reverse denoising phase using a model pre-trained on the target domain. This process effectively shifts the image style toward the target domain while retaining structural information.

Overview of the n-step diffusion and reverse process for cross-domain image translation.

Semantic Gradient Guidance (SGG)

To ensure that the translated image remains semantically consistent with the source label, the authors introduce Semantic Gradient Guidance (SGG). SGG consists of two components:

  • Local Class-regional Guidance (LCG): Ensures that pixels within specific class masks (e.g., "car", "road") exhibit the correct semantic features after denoising.
  • Global Scene-harmonious Guidance (GSG): Maintains the overall realism and cohesion of the entire scene.

Progressive Translation Learning (PTL)

Directly bridging a large domain gap in a single step is challenging. The PTL strategy decomposes the translation into $N$ intermediate steps. By gradually increasing the noise level and fine-tuning the segmentation model on these intermediate domains, the model progressively adapts to the target domain, ensuring the SGG remains reliable throughout the process.

Experimental Results

The method was evaluated on standard benchmarks: GTA5 $\rightarrow$ Cityscapes and SYNTHIA $\rightarrow$ Cityscapes.

  • State-of-the-Art Performance: On the GTA5 $\rightarrow$ Cityscapes benchmark, the approach achieved 61.9% mIoU with a ResNet-101 backbone, significantly outperforming previous GAN-based methods. Using the SegFormer backbone, the performance reached 75.3% mIoU, a 1.5% improvement over the previous best-performing method (HRDA).
  • Qualitative Superiority: Visual results show that while GANs often blur or mis-categorize small objects like traffic signs or pedestrians, the diffusion-based method preserves these fine-grained details with high precision.

Conclusion

This work presents a robust framework for DASS by leveraging the stability of diffusion models and the explicit guidance of source labels. While diffusion models require more computational time during training and inference compared to GANs, the gains in semantic consistency and overall segmentation accuracy are substantial. Future research may explore more efficient diffusion sampling techniques to further reduce the computational overhead.

Summary updated

BibTeX
@inproceedings{peng2023diffusion,
  author = {Duo Peng and Ping Hu and Qiuhong Ke and Jun Liu},
  title = {{Diffusion-based Image Translation with Label Guidance for Domain Adaptive Semantic Segmentation}},
  booktitle = {IEEE/CVF International Conference on Computer Vision},
  year = {2023},
  url = {https://openreview.net/forum?id=315cwTZmYz},
}
Figure