Profile

Settings

Loading…

← Papers

Help

FAQ

Which features require signing in?

You can read the commentary, paper info, Model Structure and related papers of public papers without signing in. Sign in to manage your account or contact us about your inquiries.

Can I upload a PDF file?

Upload papers with an arXiv or DOI link; the commentary is public to everyone. Papers whose source and terms of use can't be verified, so the commentary can't be made public, can't be uploaded. Uploading PDF files and keeping papers private are for subscribers only, and a paper uploaded as a file is saved as private only. Searching for official info by title runs only when you press the button.

Are the figures and AI commentary accurate?

Figures come only from the original paper, and only those whose terms of use are verified are shown. The commentary is written by AI and may be wrong. Check important claims, numbers and figure context against the evidence in the original paper.

I want to report a copyright issue.

Terms of use and the source of the original paper are on the Paper info tab. If there's a problem, choose "Paper content, figures and copyright" under Contact us and send the paper link, the part in question, and evidence that you hold the rights. Receiving your report doesn't confirm any rights or remove anything right away. You can see the result of the review under My inquiries.

I forgot my password.

If you signed up with email, use Forgot password in the sign-in window to reset it with your verified email. If you signed up with Google, Naver or Kakao, change your password with that service.

What should I include in an inquiry?

Tell us which screen you were on and what you were doing when the problem happened, along with the paper link. Don't include personal information such as passwords, API keys, verification codes or phone numbers. Inquiries and replies are stored in Refivu and you can see them under My inquiries.

How do I delete my account?

In Settings, under My account, press Delete account. Review what will be deleted and complete identity verification to delete your account. For other requests, choose "Account" under Contact us.

Paper commentary

DepthFormer: Exploiting Long-Range Correlation and Local Information for Accurate Monocular Depth Estimation

  • Problem Monocular depth needs both global context and fine local detail, but CNN encoders have a limited receptive field, while a plain ViT encoder lacks spatial inductive bias for local content.
  • Method DepthFormer pairs a hierarchical Transformer branch with a one-block ResNet convolution branch, then links the two with the HAHI module, which applies deformable self-attention and deformable cross-attention before a standard decoder.
  • Results Reached δ1 of 0.921 on NYU-Depth-v2 and δ1 of 0.975 in the KITTI validation comparison (Swin-L+R-50-C1). On NYU with Swin-T, adding the convolution branch and HAHI raised δ1 from 0.847 to 0.871.

Figure 5: Illustration of our proposed HAHI. The deformable self-attention module enhances the input Transformer features F. The deformable
cross-attention mod…

Fig. 5 Illustration of our proposed HAHI. The deformable self-attention module enhances the input Transformer features F. The deformable cross-attention module models the affinity between the Transformer features F and the convolution features G in a set-to-set translation manner. The output of the HAHI, Fo and Go, are sent to the decoder for the final aggregation. Due to the adoption of Swin Transformer layers to extract the hierarchical features, F exhibits different sizes and channels.

Original paper · CC BY 4.0 · Zhenyu Li, Zehui Chen, Xianming Liu, Junjun Jiang · DepthFormer: Exploiting Long-Range Correlation and Local Information for Accurate Monocular Depth Estimation · Original paper figure · Extracted the figure area from page 6 of the original PDF.

Why long-range context and local detail both matter

Estimating depth from one RGB image depends on two kinds of cue: how far-apart objects relate to each other in the scene, and how one object's appearance stays consistent over its own pixels. Convolutions have a limited receptive field, so a CNN encoder can miss the global layout, while a Transformer can model global interactions through attention but has no built-in spatial bias for fine local content.

The failure cases in Fig. 3 show large regions such as wall decorations and carpets predicted incorrectly by CNN-based methods on NYU-Depth-v2. The authors link these failures to the limited receptive field of the convolution operator, which prevents the model from using the wider context around each region.

Pilot study: ViT versus ResNet-50 by depth range

The pilot study on KITTI replaces only the encoder in a DPT-based setup, comparing ViT-Base with ResNet-50 and reporting results for depth ranges from 0m to 20m, 60m to 80m and overall. Overall, ViT-Base reaches δ1 of 0.938 against 0.952 for ResNet-50, yet on the 60m-80m range ViT-Base reaches 0.727 against 0.600.

Table 1 also shows the reverse on near objects: at 0m-20m, ViT-Base reaches 0.955 δ1 against 0.973 for ResNet-50. The authors attribute the weaker near-range result to the lack of spatial inductive bias, to detail lost in patch-wise interaction, and to the fixed token scale of ViT, which makes the multi-scale structure ambiguous.

A Transformer branch and a convolution branch

The encoder runs two branches on the same RGB input: a Transformer branch that splits the image into patches and encodes them with Transformer layers, and a convolution branch that keeps local detail. The Transformer branch uses Swin Transformer layers, so its selected layer outputs form a hierarchical set of feature maps F that differ in size and channel count.

Each Transformer layer applies LayerNorm before the multi-head self-attention and the MLP, with a residual connection around each, which gives the update below. \[ \hat{z}_l = \mathrm{MSA}(\mathrm{LN}(z_{l-1})) + z_{l-1},\quad z_l = \mathrm{MLP}(\mathrm{LN}(\hat{z}_l)) + \hat{z}_l \] Following DPT, N = 4 reassembled maps are sampled from selected layers, and the Swin Transformer variant gives multi-scale features at lower computational cost.

The convolution branch uses only the first block of a ResNet encoder, so the low-level features are not washed out by repeated convolutions, and the output G has Cg channels. Compared with TransDepth, which embeds the Transformer inside the CNN, DepthFormer lets the Transformer encode the image directly and adds the convolution branch alongside it, so the CNN does not discard information before global modeling.

Fig. 4 compares TransDepth and the proposed method on artifacts and loss of local information, where the proposed method is shown to give more consistent and sharper depth.

HAHI: enhancing features and linking the branches

HAHI receives the hierarchical Transformer features F and the convolution features G, and it aims to enhance every level of F without downsampling them to the bottleneck resolution. First, 1×1 convolutions bring all levels to one channel width Ch, and the maps are flattened and concatenated into a matrix X whose rows are the pixel feature vectors of all levels.

Queries, keys and values come from linear projections of X, as the following equation shows. \[ Q = XP_Q,\quad K = XP_K,\quad V = XP_V \] Full self-attention over all these rows would be too memory-heavy, so each query attends only to a small learned set of sampling points, which the authors justify by noting that a few key points indicate the scene structure.

The deformable attention output for a query at location p_q sums over the sampling points k, weighting the value at each shifted location by A_qk. \[ \mathrm{DAttn}(x_q,x_v,p_q)=\sum_{k\in\Omega_k} A_{qk}\, x_v(p_q+\Delta p_{qk}) \] The offsets and attention weights come from a linear projection of the query, the weights are normalized so that they sum to 1 over k, and fractional locations are read by bilinear interpolation.

A hierarchical embedding marks which feature level each query belongs to, and the output is folded back to the original resolutions to form the enhanced features.

For the affinity branch, G is projected to Gh with Ch channels and flattened into the query matrix, while the enhanced features provide the keys and values. Reference point locations are predicted from the affinity query by a linear projection followed by a sigmoid, and the attentive result Gatt is fused with G by channel-wise concatenation and a 1×1 convolution to give Go.

The fused outputs Fo and Go are passed to the decoder.

Training objective and setup

The decoder is the baseline decoder of Alhashim and Wonka, and the loss is adapted from Eigen et al. with λ = 0.85 and α = 10 for all experiments. The loss uses hi = log d̃i − log di over the T pixels with valid ground truth, and combines the mean of squared hi with a λ-weighted squared sum of hi, scaled by α.

Encoders are pretrained on ImageNet and then fine-tuned on each depth dataset, with 8 deformable attention heads and 8 reference points in the deformable modules. The optimizer is AdamW with weight decay 0.01, and the 1-cycle policy uses a learning rate of 6e-5 for the Transformer-based model and 1e-4 for the ResNet-based model, with a linear warm-up over the first 500 iterations.

The unified benchmark used for these runs is built on MMSegmentation, which the authors chose because no common codebase existed for monocular depth estimation.

Results on NYU-Depth-v2, KITTI and SUN RGB-D

The NYU training uses a 50K RGB-Depth subset, with predictions at 320×240 upsampled 2× for evaluation, and the competitor values are taken from the original papers. The Swin-L row of the ablation table gives the same numbers, so this NYU result comes from the Swin-L model with the convolution branch, HAHI and larger-scale pretraining.

On the KITTI Eigen-split validation comparison, DepthFormer with Swin-L+R-50-C1 reaches δ1 0.975, compared with 0.964 for AdaBins in the same table. This setting uses around 26K left-view training images and 697 test frames, with the Garg et al. crop for evaluation.

On the online KITTI depth benchmark, trained on the standard benchmark split and scored on the test set, DepthFormer reports SILog 10.46 and sqErrorRel 1.82, with 8.54 absErrorRel and 11.17 iRMSE in the same table. The authors state a 16% improvement on sqErrorRel and describe the submission as the most competitive result on the benchmark at the time of submission.

On SUN RGB-D, a model trained only on NYU-Depth-v2 is tested on 5050 images without fine-tuning, and DepthFormer reaches δ1 0.815 against 0.771 for AdaBins. The AdaBins number in this table is taken from Bhat et al., so it is not a rerun under the same conditions.

Ablations on the convolution branch and HAHI

On NYU with Swin-T, adding the convolution branch and HAHI raises δ1 from 0.847 to 0.871, and HAHI alone on Swin-T raises δ1 to 0.866. On ResNet-50, HAHI alone raises δ1 from 0.811 to 0.866, and adding larger-scale pretraining on top of HAHI does not raise it further (0.865). The larger-scale pretraining row for Swin-L reaches 0.921, and the authors used a 22K-ImageNet ResNet-50-x3 so that the ResNet comparison is fair.

With Swin-T and the convolution branch as backbone, applying deformable self-attention over all hierarchical levels lowers RMS by 4.9% relative to single-level attention. The authors infer that large discrepancies between the heterogeneous features are the reason, and that multi-level aggregation aligns the features before affinity modeling.

Within the convolution branch study on NYU, using only the first ResNet block gives the best accuracy, and adding more blocks lowers it. The authors attribute the decline to repeated convolutions washing out low-level features and reducing spatial resolution. Using only the first block also reduces training time by 2.5× or more, which the authors note lets the Transformer branch scale to larger models.

Limitations

The authors state that the HAHI module has no theoretical guarantees, and that the applicability of DepthFormer needs further study. They also suggest that global attention in the Transformer may be more than needed and that other modalities, such as sparse LiDAR, could be included in future work.

Competitor numbers in the NYU and KITTI tables come from the original papers or from official codes, so they are not controlled reruns. The KITTI benchmark result is a single submission on the online test set.

The fine-grained HAHI and convolution-branch ablations are run on NYU only, and the KITTI detailed ablation covers the ViT-Base and Swin-T rows with and without CB and HAHI. The inference time was measured for DepthFormer without HAHI on the KITTI validation set at 352×1216 on a single RTX 3060 GPU, so it does not describe the full model.

Paper info

Authors
Zhenyu Li, Zehui Chen, Xianming Liu, Junjun Jiang
Venue
arXiv · Preprint
First published
2022-3-27
Added
2026-11-6
Updated
2022-3-27
Version
v1
arXiv
2203.14211
DOI
10.1007/s11633-023-1458-0
Category
cs.CV
Original paper terms
CC BY 4.0
What we show
Paper info, commentary and permitted figures from the original paper

AI commentary is a separate explanation from the original paper and may contain errors. The original paper and figures follow each source's terms of use and any rights noted separately.

Abstract

This paper aims to address the problem of supervised monocular depth estimation. We start with a meticulous pilot study to demonstrate that the long-range correlation is essential for accurate depth estimation. Therefore, we propose to leverage the Transformer to model this global context with an effective attention mechanism. We also adopt an additional convolution branch to preserve the local information as the Transformer lacks the spatial inductive bias in modeling such contents. However, independent branches lead to a shortage of connections between features. To bridge this gap, we design a hierarchical aggregation and heterogeneous interaction module to enhance the Transformer features via element-wise interaction and model the affinity between the Transformer and the CNN features in a set-to-set translation manner. Due to the unbearable memory cost caused by global attention on high-resolution feature maps, we introduce the deformable scheme to reduce the complexity. Extensive experiments on the KITTI, NYU, and SUN RGB-D datasets demonstrate that our proposed model, termed DepthFormer, surpasses state-of-the-art monocular depth estimation methods with prominent margins. Notably, it achieves the most competitive result on the highly competitive KITTI depth estimation benchmark. Our codes and models are available at https://github.com/zhyever/Monocular-Depth-Estimation-Toolbox.

Quote from the paper

Zhenyu Li, Zehui Chen, Xianming Liu, Junjun Jiang (2022). DepthFormer: Exploiting Long-Range Correlation and Local Information for Accurate Monocular Depth Estimation. arXiv:2203.14211v1. https://doi.org/10.1007/s11633-023-1458-0

BibTeX
@article{li2022depthformer,
  title = {{DepthFormer: Exploiting Long-Range Correlation and Local Information for Accurate Monocular Depth Estimation}},
  author = {Zhenyu Li and Zehui Chen and Xianming Liu and Junjun Jiang},
  year = {2022},
  eprint = {2203.14211},
  archivePrefix = {arXiv},
  doi = {10.1007/s11633-023-1458-0},
  url = {https://arxiv.org/abs/2203.14211v1}
}

See related papersBrowse other papers

Paper preview
Account security

Connect Google account

If you connect a Google account, you can sign in with it too.

Refivu

Delete account

Refivu
Refivu

Sign up