All models

DAFormer

A Transformer segmentation network built for adapting from synthetic to real images without labels.

Segmentation · 2,568 operations Checked

100%

Showing the top corner; full diagram not loaded yetShowing a small copy; full diagram not loaded yetLarge diagram, not loaded yet

Open SVG

This diagram has 2,568 operations (7 KB) and is drawn when you ask.

Open in a new tab

Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.

At a glance

Parameters
85.2M
Operations
2,568
Framework
PyTorch
Recurrent
No
Published
CVPR 2022
Cited by
656 (as of 26 October 2026)
Authors
Lukas Hoyer, Dengxin Dai, Luc Van Gool
License
Apache-2.0
Checked
Passed: the trace was replayed operation by operation and matched the model's own output for this input.

Files

The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.

Details
Stable ID
m15526
Graph hash
b47d433679a5dfeee812081f59d7796747d8ef0084d3cc22a194bae6bd4450a9
Skeleton hash
b5d06d9059403b5bcfbf5af5be3be86c135ff55f6fee00c0d1d45d40cb566fb2
Architecture hash
17c5eb634f438771dbc07b849e6d028085c4d85d1f20262dc01f59ed12c0f203
Diagram SHA-256
80dc472aa5f090c8db63253571fa60eee27ec61e171966a0b036eced88491a1c
TorchLens version
2.36.0
Renderer
graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
Check
Forward pass replayed in PyTorch

What it is

DAFormer is a semantic segmentation method for unsupervised domain adaptation (UDA), where a model is trained on synthetic data and adapted to real images without their annotations. The paper argues that earlier UDA methods were mostly based on outdated network architectures.

The network has a Transformer encoder and a multi-level context-aware feature fusion decoder. The encoder is MiT-B5, which produces a feature pyramid with 64, 128, 320 and 512 channels. The decoder embeds each level to the same number of channels with a 1x1 convolution, upsamples the features to the size of the first level and concatenates them. It then fuses the stack with parallel 3x3 depthwise separable convolutions at different dilation rates, similar to ASPP but without global average pooling.

Three training strategies stabilize the training and help avoid overfitting to the source domain. Rare Class Sampling on the source domain improves the quality of the pseudo-labels, while a Thing-Class ImageNet Feature Distance and a learning rate warmup promote feature transfer from ImageNet pretraining. The paper reports 68.3 mIoU on GTA to Cityscapes, up from 57.5, and 60.9 mIoU on Synthia to Cityscapes, up from 55.5.

Key idea. The paper benchmarks network architectures for UDA semantic segmentation and proposes DAFormer, a Transformer encoder with a context-aware feature fusion decoder trained with three stabilizing strategies.

  • daformer
  • domain-adaptive semantic segmentation
  • unsupervised domain adaptation
  • uda
  • semantic segmentation
  • synthetic-to-real
  • gta to cityscapes
  • rare class sampling
  • context-aware feature fusion

AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.

Cite the paper

@misc{hoyer2022daformerimprovingnetworkarchitectures,
      title={DAFormer: Improving Network Architectures and Training Strategies for Domain-Adaptive Semantic Segmentation}, 
      author={Lukas Hoyer and Dengxin Dai and Luc Van Gool},
      year={2022},
      eprint={2111.14887},
      archivePrefix={arXiv},
      primaryClass={cs.CV},
      url={https://arxiv.org/abs/2111.14887}, 
}