potentialpaper

BiHashFormer: Hash-Driven Dual-Branch Transformer for Efficient Object Detection in HRW Shots

Jingchen Huang, Wenxi Li, Chenyang Lyu, Mo-Ran Liu, Haozhe Lin, Yuchen Guo

NeurIPS 2026

Edit this page

Or clone it with git

Run in a terminal:

Needs Git LFS. To push, use an API key from your profile as the password.

Or let your agent set it up

It checks and sets up everything: signing in, git, the clone, credentials and an SSH key.

TL;DR. BiHashFormer uses binary hashing in parallel compression and compensation branches to improve gigapixel person detection, reducing backbone computation by 37.5% compared with SparseFormer.

Abstract. Recent advances in gigapixel-level imaging have brought High-Resolution Wide shots to the forefront of research. However, these images present significant challenges: extreme sparsity of foreground, gigapixel-level resolutions and interleaving of foreground and background. This causes traditional detectors and attention mechanisms to be hindered by background, resulting in inefficiency and inaccuracy. To tackle this problem, we propose BiHashFormer, a dual sparsified branch transformer built on hashing. RoI Selector will predict the foreground proportion for top-k selecting target-containing windows. The compression branch processes windows selected and refines attention into HashAttention by discarding half of the key–value pairs, reducing cost and improving efficiency. The compensation branch uses HashMiner to perform low-cost hash searches in the remaining regions, recovering features of missed objects. Experiments confirm that the selection relationship in HashAttention is one-way and reveal the preference of different queries for keys. In experiments on the gigapixel benchmark PANDA, BiHashFormer reduces 37.5% backbone FLOPs while improving AP50\text{AP}_{50} to 81.0%. Moreover, this parallel dual-branch structure allows the model to avoid inference delays caused by inter-branch dependencies, while achieving much greater stability than single-branch models, specially with low rates of RoI selection.

Are you an author? Claim this paper to see who's reading it, with views and other statistics, and to write about it here.

Claim this paper
How does this paper connect to your work? Write how you built on it, compared with it or reproduced it, or add a summary, a critique or errata.
Or make it interactive:
Start writing

edit · history

DateVersionSubmitted toPDFEvidence
1 May 2026NeurIPS 2026submittedNeurIPS 2026Accept (poster)reviews ↓[1]PDF[1]
Missing a version?

NeurIPS 2026

Accept (poster) · 3 reviews · OpenReview

Updated 25 Nov 2026, 03:46 UTC.

Program Chairs · DecisionOpenReview ↗
Decision
Accept (poster)
Read decision
Meta-review

This submission received comments from three reviewers, whose opinions show a slight divergence. The core concerns raised are as follows,

(1)The novelty of HashAttention and HashMiner is called into question, as they appear closely related to recent binary/hash-based attention mechanisms and classical clustering methods, while lacking theoretical guarantees that Hamming projection accurately preserves the original attention quality.

(2)The experimental evaluation is severely limited in scope, with the evaluation only based on the single-category PANDA dataset. It lacks validation in complex backgrounds and multi-category scenarios (e.g., COCO), as well as comparisons against modern vision foundation models (e.g., DINOv3) and mainstream sparse attention baselines.

(3)The underlying assumption of the method is limited. The premise that "backgrounds exhibit low variance while foregrounds exhibit high variance" may easily fail in complex, high-variance backgrounds like forests or grasslands, leading to inaccurate region selection. In addition, crucial performance metrics and implementation details are missing, such as training time and convergence speed, and the rationale behind key hyperparameter choices (e.g., a Hamming dimension of 32 and the number of Hash Blocks) remains insufficiently explained.

The AC concurs with the reviewers' concerns and strongly encourages the authors to provide more detailed clarifications and comprehensive analyses during the rebuttal phase.

Final justification

AC has carefully read the authors’ response and the reviewers’ final feedback. There is some divergence among the reviewers regarding the acceptance of this paper: Reviewers uvsK and qpgE are inclined to accept after reading the authors’ response, while Reviewer aigw still has concerns about novelty, though with a lower confidence score. The AC believes that the authors have effectively addressed the key concerns in several aspects, including the novelty and theoretical justification of HashAttention and HashMiner, the expanded experimental scope with additional baselines and datasets, and the clarification of assumptions, efficiency, and hyperparameter choices. Therefore, the AC recommends accepting this paper. In the final version, the authors should incorporate these clarifications and experimental results into the paper.

Area Chair VtjG · Meta-reviewOpenReview ↗
Read meta-review
Meta-review

This submission received comments from three reviewers, whose opinions show a slight divergence. The core concerns raised are as follows,

(1)The novelty of HashAttention and HashMiner is called into question, as they appear closely related to recent binary/hash-based attention mechanisms and classical clustering methods, while lacking theoretical guarantees that Hamming projection accurately preserves the original attention quality.

(2)The experimental evaluation is severely limited in scope, with the evaluation only based on the single-category PANDA dataset. It lacks validation in complex backgrounds and multi-category scenarios (e.g., COCO), as well as comparisons against modern vision foundation models (e.g., DINOv3) and mainstream sparse attention baselines.

(3)The underlying assumption of the method is limited. The premise that "backgrounds exhibit low variance while foregrounds exhibit high variance" may easily fail in complex, high-variance backgrounds like forests or grasslands, leading to inaccurate region selection. In addition, crucial performance metrics and implementation details are missing, such as training time and convergence speed, and the rationale behind key hyperparameter choices (e.g., a Hamming dimension of 32 and the number of Hash Blocks) remains insufficiently explained.

The AC concurs with the reviewers' concerns and strongly encourages the authors to provide more detailed clarifications and comprehensive analyses during the rebuttal phase.

Final justification

AC has carefully read the authors’ response and the reviewers’ final feedback. There is some divergence among the reviewers regarding the acceptance of this paper: Reviewers uvsK and qpgE are inclined to accept after reading the authors’ response, while Reviewer aigw still has concerns about novelty, though with a lower confidence score. The AC believes that the authors have effectively addressed the key concerns in several aspects, including the novelty and theoretical justification of HashAttention and HashMiner, the expanded experimental scope with additional baselines and datasets, and the clarification of assumptions, efficiency, and hyperparameter choices. Therefore, the AC recommends accepting this paper. In the final version, the authors should incorporate these clarifications and experimental results into the paper.

1 comment
Authors · CommentOpenReview ↗

Clarifications Addressing the Area Chair’s Key Concerns

We thank the Area Chair for the careful assessment and for highlighting the main concerns raised by the reviewers. We have addressed each point in the corresponding reviewer responses as follows.

(1) Novelty and theoretical justification. The distinctions of HashAttention and HashMiner from prior binary/hash-based attention and classical clustering methods are addressed in our response to Reviewer aigw. The theoretical analysis explaining why the learned Hamming projection can preserve important query-key interactions and attention quality is provided in our response to Reviewer qpgE.

(2) Experimental scope and baseline comparisons. The evaluation using the DINOv3 foundation model is reported in our response to Reviewer qpgE. The additional results on COCO, DOTA, and VisDrone, together with comparisons against Linformer and XAttention, are reported in our response to Reviewer uvsK.

(3) Assumptions, efficiency, and hyperparameters. The robustness of the RoI Selector in complex, highly textured backgrounds, the training time and convergence analysis, and the choices of the 32-dimensional Hamming space and three prototype codes are addressed in our response to Reviewer uvsK. The rationale for the four-stage Hash Block depths [2, 2, 6, 2] is addressed in our response to Reviewer aigw.

We hope these detailed responses and additional analyses resolve the concerns summarized above, and we thank the Area Chair for considering our clarifications.

Reviewer aigwOpenReview ↗
Rating
3/6
Confidence
3/5
Quality
3/4
Clarity
2/4
Significance
3/4
Originality
2/4
Contribution type
general
Ethical concerns
NO or VERY MINOR ethics concerns only
Read review
Summary

This work addresses the central challenge of High-Resolution Wide (HRW) object detection by introducing BiHashFormer, a dual-branch transformer architecture. To handle the extreme foreground sparsity of gigapixel images, a dual-branch framework is proposed where a compression branch featuring "HashAttention" (which maps queries and keys into a low-dimensional Hamming space to aggressively prune attention pairs), and a compensation branch that uses "HashMiner" to recover missed small targets via learned binarized prototype codes. Empirical results show efficiency and accuracy gains over SoTA on several benchmarks.

Strengths and weaknesses

Strengths:

The dual-branch framework provides a practical solution to the foreground sparsity and compute-scaling problems in HRW scenarios. The architecture demonstrates compelling efficiency and accuracy gains on several benchmarks, outperforming some SoTA methods.

Weaknesses:

The claims of the paper regarding the innovation of "HashAttention" are heavily undermined by recent literature. The core mechanism of mapping tokens to a 1-bit Hamming space for efficient distance-based attention pruning has been established in recent works (such as HashAttention https://arxiv.org/html/2412.14468v2 and BinaryFormer https://ieeexplore.ieee.org/document/10531134). Major revisions seems needed to appropriately contextualize the work within the current landscape of binary attention mechanisms.

While the proposed "HashMiner" seems like classical clustering methods in Machine Learning, which has limited novelty.

Questions

Can you give some intuition why the foreground proportion /rho can be predicted? It is mentioned "The model consists of four stages, with the number of Hash Blocks in each stage set to [2,2,6,2]." How is this parameter chosen?

Limitations

No. It seems the answer to Question 2 (limitations) in the Checklist only points out an interesting visual pattern that requires further study ("The reason behind a pattern in section 4.4 need further investigation").

Final justification

Thanks for the clarifications. I have raised my rating a bit.

Formatting concerns

Many citations in the manuscript should use \citep

1 comment
Authors · RebuttalOpenReview ↗
Rebuttal

We thank the reviewer for raising this important novelty concern. Our contribution is not binary or Hamming-space attention itself, but its unified use in HRW detection to refine within-window token interactions and efficiently retrieve missed small objects from non-RoI regions.

How is the contribution different from HashAttention and BinaryFormer?

We acknowledge HashAttention [1] and BinaryFormer [2] as important prior work and will cite both explicitly.

BinaryFormer [2] focuses on numerical efficiency: it binarizes ViT weights and switches between binary attention modes to replace expensive matrix operations with additions and bit operations. BiHashFormer does not binarize Transformer weights or the retained attention computation. It uses binary codes only to decide which tokens should interact, then computes attention with the original key-value features. BinaryFormer reduces the numerical cost of an existing interaction pattern; our method learns a query-dependent sparse interaction pattern. It also does not search rejected image regions for missed objects.

HashAttention [1] is closer to our compression branch because it also maps queries and keys into Hamming space for token retrieval. We acknowledge it as prior art for this general mechanism. However, it is a post-training sparse-inference module for pretrained autoregressive LLMs. Its mappings learn to reproduce pivotal-token labels derived from full attention, with the goal of approximating the pretrained model while reducing KV-cache access. In contrast, our Hamming projectors are trained end-to-end with the detection backbone, without full-attention top-kk labels or a teacher attention matrix. The interaction graph is therefore learned directly for HRW detection.

More importantly, our purpose is not merely to approximate dense attention. Large HRW windows contain strongly interleaved foreground and background tokens. Dense attention forces every query to aggregate from all tokens, allowing background evidence to dilute foreground features. We instead retain the closest 50% of keys for each query in the learned Hamming space and perform full-precision attention only on these interactions.

Evidence already reported in the submitted main paper (Table 2):

Interaction within each selected window Compression GFLOPs ↓ AP50\mathrm{AP}_{50} ↑ APmedium\mathrm{AP}_{medium} ↑ APlarge\mathrm{AP}_{large} ↑
Dense attention: Q→100Q\rightarrow100\\%K 80.11 0.797 0.783 0.837
Hamming-routed attention: Q→50Q\rightarrow50\\%K 38.12 0.810 0.792 0.847

Our routing reduces compression-branch computation by 52.4% and improves AP50\mathrm{AP}_{50} by 1.3 points. Thus, the removed interactions are not simply an approximation loss accepted for speed; removing background-dominated interactions improves the attention result.

The routing direction also matters. A query represents the information a token requires, whereas a key represents the information another token provides. Reversing Q→50Q\rightarrow50\\%K to K→50K\rightarrow50\\%Q lowers AP50\mathrm{AP}_{50} from 0.810 to 0.785, while measured computation differs by only 0.02 GFLOPs. The gain therefore comes from query-conditioned interaction rather than generic binary clustering.

HashMiner appears similar to classical clustering methods, limiting its novelty.

The key problem addressed by HashMiner is efficient recovery, not data clustering. HRW images contain an enormous non-RoI region: aggressive RoI selection saves computation, but small or difficult objects may be routed into this region. Running dense attention over all rejected windows would negate most of the savings. HashMiner instead turns this expensive missed-object search into a small number of Hamming-distance decisions.

Specifically, it reuses the key projector learned by the compression branch to map every non-RoI token into the same 32-bit semantic space. A token is recovered when its binary code falls within radius rr of a learned target prototype:

Xcomp={x,|,min⁡idH!(bK(x),ci)≤r}.\mathcal{X}_{\mathrm{comp}} = \left\lbrace x \\,\middle|\\, \min_i d_H\\!\left(b_K(x),c_i\right)\le r \right\rbrace.

Only retrieved tokens receive additional feature extraction. The compensation branch can therefore search the much larger non-RoI region using inexpensive binary comparisons, while reserving costly feature extraction for a small set of likely missed targets.

HashMiner also differs fundamentally from conventional clustering. It does not iteratively assign non-RoI samples to clusters or recompute centroids, either during training or inference. Its prototypes are trainable binary codes learned end-to-end through the task-specific loss

Lproto=Lintra+Lcross.\mathcal{L}_{\mathrm{proto}} = \mathcal{L}_{\mathrm{intra}}+\mathcal{L}_{\mathrm{cross}}.

Lintra\mathcal{L}_{\mathrm{intra}} learns target-related prototypes from the target-rich keys selected by the compression branch, while Lcross\mathcal{L}_{\mathrm{cross}} separates the prototypes so that their Hamming-radius coverage does not collapse or overlap. At inference, the prototypes are fixed and used only for fast radius tests. HashMiner is therefore a learned retrieval mechanism tied to the detection objective and the shared feature space of the two branches, rather than a post-hoc clustering algorithm.

The 32-bit space and the three prototypes have complementary roles. The Hamming space preserves fine-grained differences among categories, instances, and object parts, whereas the prototypes compactly anchor reusable target structures. They are not three class centers and do not perform classification; the detector head remains responsible for category prediction. Figure 3 supports this organization: head queries retrieve keys across the whole object, while body and background queries emphasize foreground-background boundaries.

The submitted main paper already validates this design in Tables 3 and 4. A 32-dimensional space gives the best AP50\mathrm{AP}_{50} (0.810 versus 0.801 for 16 dimensions and 0.805 for 64), while three prototypes give the best APsmall\mathrm{AP}_{small} (0.591 versus 0.498 with one prototype and 0.582 with five). These results show that the selected configuration balances semantic capacity and compact retrieval rather than assigning one prototype to each category.

Evidence already reported in the submitted supplementary material (Table X3):

Non-RoI compensation Compensation GFLOPs ↓ AP50\mathrm{AP}_{50} ↑ APsmall\mathrm{AP}_{small} ↑
None 0 0.786 0.287
Generic attention module 13.28 0.793 0.311
Hamming prototype retrieval (ours) 8.29 0.810 0.591

The proposed branch raises APsmall\mathrm{AP}_{small} from 0.287 to 0.591 and outperforms generic attention while using 37.6% fewer compensation GFLOPs. As reported in Section 4.3 of the submitted main paper, it searches approximately 85% of all windows but accounts for only 17.9% of the two branches' computation. These results directly support our objective: efficiently finding small targets that would otherwise be missed in the vast HRW background.

This recovery principle is transferable: any detector that prunes windows, patches, proposals, or tokens faces the same recall-efficiency trade-off. A learned Hamming retrieval branch can search the rejected region without restoring dense processing over the full image.

We will revise the paper to position the contribution as an HRW-specific dual-branch framework that uses Hamming space both to refine foreground-window interactions and to recover missed small objects, rather than as the first binary or Hamming-space attention method.

Why are the stage depths [2, 2, 6, 2]?

This configuration is not a searched hyperparameter or a claimed contribution. We follow the standard Swin-T depths [2, 2, 6, 2] [3], also used by SparseFormer [4], to keep the four-stage allocation and total of 12 blocks fixed. This controls backbone capacity so that the comparison reflects our routing and interaction mechanisms rather than a depth difference. We will state this fair-comparison rationale explicitly.

References

[1] Aditya Desai et al. HashAttention: Semantic Sparsity for Faster Inference. ICML 2025.

[2] Miaohui Wang, Zhuowei Xu, Bin Zheng, and Wuyuan Xie. BinaryFormer: A Hierarchical-Adaptive Binary Vision Transformer (ViT) for Efficient Computing. IEEE Transactions on Industrial Informatics, 20(8):10657–10668, 2024.

[3] Ze Liu et al. Swin Transformer: Hierarchical Vision Transformer Using Shifted Windows. ICCV 2021.

[4] Wenxi Li et al. SparseFormer: Detecting Objects in HRW Shots via Sparse Vision Transformer. ACM Multimedia 2024.

Reviewer uvsKOpenReview ↗
Rating
4/6
Confidence
4/5
Quality
3/4
Clarity
3/4
Significance
3/4
Originality
3/4
Contribution type
use_inspired
Ethical concerns
NO or VERY MINOR ethics concerns only
Read review
Summary

This paper have the practical usage value. The former work is based on fixed ratio to select regions, which is not flexible enough. This paper introduce the dynamic ρ + compensation branch, which is friendly to actual implementation. Transformer sparse attention is quite a new idea, comparing to the traditional solution of projecting high-dimensional features into Hamming space. It is a hardware-friendly solution.

Strengths and weaknesses

In the paper, it shows a good balance between efficiency and accuracy by using hash space for lightweight screening. Figure 3 in the paper shows that Queries from the head region will attend to the whole body, while Queries from body/background pay more attention to the foreground-background boundary. This indicates that the hash projection indeed learned semantically meaningful similarity, not selecting blindly. However, in this paper, it assumes background has low variance, foreground has high variance. It is true for sky and road scenes. But for complex backgrounds such as forests, grasslands scenes with small targets, the variance may also be very high. This might cause inaccurate region selection. In this paper, such complex scenes is not sufficient studied.

Questions

The paper says that too small k will cause semantic entanglement, and too large k will lose low-rank advantage. In the paper the hamming space dimension of 32 is chosen. But why 32 instead of 16 or 64? The paper says "based on ablation experiments," but can 3 prototypes cover all target semantics? On PANDA with only the "person" class it is okay, but how about for multi-class scenarios like COCO?

Limitations
  1. The experiments in this paper are only based on PANDA (single class: person), while DOTA and VisDrone are placed into the supplementary materials.
  2. Not enough comparison with other SOTA sparse attention methods (such as XAttention, Linformer).
  3. Did not report training time or convergence speed, only provided FLOPs.
  4. Although the paper's supplementary material mentions that stability was evaluated, actual reproduction may be still a risk.
Final justification

Thanks for the clarification, i have adjusted the rating with the updated contibution type.

Formatting concerns

No concern

1 comment
Authors · RebuttalOpenReview ↗
Rebuttal

We thank the reviewer for the positive assessment and for identifying several important points concerning the empirical scope and reproducibility of the paper. We address each concern below.

How robust is the RoI Selector to highly textured backgrounds?

This mechanism does not assume that every background region has intrinsically low variance. Following SparseFormer (SF) [1], we use “variance-based” for consistency. Simple-texture regions such as sky, water, and roads are filtered in shallow layers. Complex backgrounds such as foliage or buildings may initially score highly, but local attention progressively aligns their semantically homogeneous features, reducing their residuals and allowing deeper selectors to discard them.

Moreover, non-RoI windows are not removed. HashMiner searches them in Hamming space and recovers target-like tokens, including small objects missed in textured backgrounds. Supplementary Table X3 confirms this role: removing compensation reduces APsmall\mathrm{AP}_{small} from 0.591 to 0.287, whereas HashMiner achieves 0.591 with only 8.29 GFLOPs.

Why use a 32-dimensional Hamming space and three prototype codes?

The two hyperparameters have complementary roles: kk controls the semantic capacity of the Hamming space, while the prototypes provide compact retrieval anchors. They do not encode one class per code. HashAttention uses Hamming distance only to select key-value pairs and then computes attention in the original continuous feature space. The prototypes likewise retrieve missed foreground tokens; category classification remains the detector head's task.

With k=32k=32, categories, instances, and object parts remain distinguishable while sharing class-agnostic structure. Object cores and boundaries form reusable foreground modes separated from background. Figure 3 supports this view: head queries cover the full object, whereas body and background queries emphasize foreground-background boundaries. Thus, 32 bits preserve fine semantics, while three prototypes anchor shared foreground structures rather than three class identities.

Tables 3 and 4 support this coupling. With k=16k=16, semantic entanglement yields 0.801 AP50\mathrm{AP}_{50} and 55.01 GFLOPs; k=32k=32 reaches 0.810 with 47.31 GFLOPs; k=64k=64 lowers accuracy to 0.805 with similar cost (46.95 GFLOPs). Likewise, one prototype is too coarse (APsmall=0.498\mathrm{AP}_{small}=0.498), three are optimal (APsmall=0.591\mathrm{AP}_{small}=0.591, AP50=0.810\mathrm{AP}_{50}=0.810), and five add fragmentation without improvement (APsmall=0.582\mathrm{AP}_{small}=0.582, AP50=0.806\mathrm{AP}_{50}=0.806).

COCO [2] directly tests this design across 80 categories, as reported in Table A. Swin-T accuracy follows Swin Transformer [3] under 3$\times$ Mask R-CNN. GFLOPs-O uses the same backbone-and-neck-only scope as our paper at 1333×8001333\times800 input. Because COCO contains denser foreground than PANDA, its average selection ratio increases from 0.147 to 0.30, routing more windows through the compression branch.

Backbone Prototype codes COCO AP AP50\mathrm{AP}_{50} APsmall\mathrm{AP}_{small} GFLOPs-O Compensation GFLOPs
Swin-T -- 46.0 68.1 31.2 138.34 --
BiHashFormer 1 47.0 70.2 32.4 86.96 5.01
BiHashFormer 3 48.3 71.5 34.8 89.04 7.08
BiHashFormer 5 47.2 70.8 33.1 96.83 14.88

Table A. Prototype-number ablation and comparison with Swin-T on COCO.

Three prototypes improve over Swin-T by 2.3 AP, 3.4 AP50\mathrm{AP}_{50}, and 3.6 APsmall\mathrm{AP}_{small} with 35.6% fewer GFLOPs. One prototype under-represents foreground modes; five increase computation by 8.8% without improving accuracy. Thus, three prototypes remain the best accuracy-efficiency choice on COCO.

Does the evaluation generalize beyond PANDA?

PANDA [4] is human-centric, while DOTA [5] and VisDrone [6] cover remote-sensing and drone-view HRW scenes with different categories, scales, and backgrounds. On DOTA, BiHashFormer improves DINO+SparseFormer from 77.94 to 79.52 mAP while reducing FLOPs from 174.31 to 89.63. On VisDrone, it improves AP50\mathrm{AP}_{50} from 0.554 to 0.602 and AR100\mathrm{AR}_{100} from 0.408 to 0.452. These results establish transfer across distinct HRW domains.

COCO [2] complements them as a non-HRW benchmark with 80 categories. Its results show that BiHashFormer also transfers to conventional-resolution, multi-category detection. Together, the four datasets cover human-centric HRW, aerial HRW, drone-view HRW, and non-HRW multi-class scenes.

How does BiHashFormer compare with XAttention and Linformer?

Linformer [7] compresses K/V to a fixed rank before attention, creating an information bottleneck that can merge weak small-object features with background. HashAttention instead uses low-dimensional Hamming codes only for query-specific selection, then computes attention with the original continuous features.

XAttention [8] selects blocks using antidiagonal scores. Its reported acceleration targets 8k--256k-token contexts, whereas our 21×2121\times21 windows contain only 441 tokens, making block selection coarser and overhead harder to amortize. Unlike both methods, BiHashFormer also uses HashMiner to recover targets from non-RoI regions. Table B compares the methods under the same DINO pipeline [9]:

Attention GFLOPs-O Latency AP50\mathrm{AP}_{50}
Linformer 57.48 3.15 s 0.792
XAttention 64.93 3.25 s 0.799
DINO+SparseFormer 75.71 3.5 s 0.780
BiHashFormer 47.31 2.8 s 0.810

Table B. Comparison with efficient and sparse attention methods under the DINO pipeline.

What are the training cost and convergence speed?

All detectors use the same 36-epoch MMDetection [10] protocol. Table C reports wall-clock efficiency and convergence:

Method Time/epoch Total time Epoch to 0.75 AP50\mathrm{AP}_{50} Time to 0.75 AP50\mathrm{AP}_{50} Final AP50\mathrm{AP}_{50}
DINO+SparseFormer 38.7 min 23.2 h 28 18.0 h 0.780
DINO+BiHashFormer 32.8 min 19.7 h 23 12.6 h 0.810

Table C. Training time and convergence under the same 36-epoch protocol.

DINO+BiHashFormer reduces total training time by 15.1% and reaches 0.75 AP50\mathrm{AP}_{50} five epochs, or 5.5 hours, earlier than DINO+SparseFormer.

Inference latency also confirms practical speedups: BiHashFormer takes 11.1 s on AGX Orin and 2.8 s on RTX 4090, versus 13.9 s and 3.5 s for DINO+SparseFormer.

How stable and reproducible is BiHashFormer?

Across ten random initialization seeds, every run achieves AP50∈[0.809,0.812]\mathrm{AP}_{50}\in[0.809,0.812]--only a 0.3-point range. Reproduction therefore does not require seed search or checkpoint cherry-picking: a single trained model can be deployed with negligible seed-dependent loss. The supplement also provides pseudocode for STE, prototype lookup, HashAttention, CPS, and adaptive routing, plus latency on AGX Orin and RTX 4090. Together, these results support stable reproduction and edge deployment.

References

[1] Wenxi Li et al. SparseFormer: Detecting Objects in HRW Shots via Sparse Vision Transformer. ACM Multimedia 2024.

[2] Tsung-Yi Lin et al. Microsoft COCO: Common Objects in Context. ECCV 2014.

[3] Ze Liu et al. Swin Transformer: Hierarchical Vision Transformer Using Shifted Windows. ICCV 2021.

[4] Xueyang Wang et al. PANDA: A Gigapixel-Level Human-Centric Video Dataset. CVPR 2020.

[5] Gui-Song Xia et al. DOTA: A Large-Scale Dataset for Object Detection in Aerial Images. CVPR 2018.

[6] Dawei Du et al. VisDrone-DET2019: The Vision Meets Drone Object Detection in Image Challenge Results. ICCV Workshops 2019.

[7] Sinong Wang et al. Linformer: Self-Attention with Linear Complexity. arXiv:2006.04768, 2020.

[8] Ruyi Xu et al. XAttention: Block Sparse Attention with Antidiagonal Scoring. arXiv:2503.16428, 2025.

[9] Hao Zhang et al. DINO: DETR with Improved DeNoising Anchor Boxes for End-to-End Object Detection. arXiv:2203.03605, 2022.

[10] Kai Chen et al. MMDetection: Open MMLab Detection Toolbox and Benchmark. arXiv:1906.07155, 2019.

Reviewer qpgEOpenReview ↗
Rating
4/6
Confidence
4/5
Quality
3/4
Clarity
3/4
Significance
2/4
Originality
3/4
Contribution type
use_inspired
Ethical concerns
NO or VERY MINOR ethics concerns only
Read review
Summary

This paper innovatively presents BiHashFormer, a dual-branch vision transformer for efficient object detection in High-Resolution Wide (HRW) images. The work primarily addresses three critical challenges: extreme sparsity of the foreground, prohibitive computational costs, and attention dilution caused by the interleaving of foreground and background. To tackle these issues, the proposed architecture introduces three key components: (1) an RoI Selector, (2) a Compression Branch, and (3) a Compensation Branch. The authors conduct extensive experiments, and results on the PANDA benchmark dataset demonstrate that, compared with SparseFormer, BiHashFormer achieves substantial reductions in backbone FLOPs while considerably improving the AP50 metric, yielding promising overall performance.

Strengths and weaknesses

Strengths: This paper proposes BiHashFormer, a hash-driven dual-branch transformer for object detection in High-Resolution Wide (HRW) images. Overall, the work exhibits moderate novelty and clear practical value, and the experimental results demonstrate its effectiveness.

Weaknesses: The experimental validation is limited in breadth. The method is evaluated only on PANDA in the main text, and the supplementary results on DOTA and VisDrone are neither presented nor analyzed in sufficient depth to verify its cross-task generalization ability. The comparison baselines are somewhat narrow: beyond SparseFormer, the paper lacks systematic comparisons against more recent detection backbones or architectures specifically designed for high-resolution inputs.

Questions
  1. The paper lacks comparisons with modern vision foundation models. It remains unclear whether the proposed method still works when equipped with a powerful backbone. Moreover, the pretraining stage in the pipeline is relatively weak. Please detail the pretraining settings and perform experiments on a strong pretrained backbone such as DINOv3 while keeping the detection head unchanged.
  2. There is insufficient theoretical analysis on how Hamming projection impacts attention approximation quality. Is there a theoretical guarantee that the top 50% keys chosen by Hamming distance in the projected space match those selected by full attention in the original space?
  3. It is unclear whether the method can generalize to other tasks. Additional experiments on other vision tasks (such as semantic segmentation) are expected.
Limitations

yes

Final justification

Thank you for the clarification. I have adjusted the rating accordingly.

Formatting concerns

None

1 comment
Authors · RebuttalOpenReview ↗
Rebuttal

We thank the reviewer for the constructive feedback. We address strong pretrained backbones, 50% KV retention, and segmentation generalization below.

Evaluation with a strongly pretrained backbone and pretraining details.

With identical DINOv3 initialization and 36 epochs, BiHash-DINOv3 gains 4.0 AP50 and 11.6 APsmall points, cuts GFLOPs-O/latency by 64.4%/56.5%, and delivers 2.31× throughput.

The original manuscript results were trained from scratch. Here both models instead use the same official ViT-S+/16 checkpoint [1] and 36-epoch schedule, preventing unequal pretraining.

ViT-S+/16 (12 blocks, approximately 29M parameters) closely matches Swin-T/BiHashFormer ([2,2,6,2], 12 blocks) without a capacity advantage.

We group its single-resolution blocks as [2,2,6,2] without downsampling. In every block, the RoI Selector routes ranked spatial windows to HashAttention compression or HashMiner compensation; the class and four register tokens remain global and bypass routing. Branch outputs are merged and restored to the original token order.

Both models load all shared pretrained components; only routing, Hamming projection, prototype, and compensation modules start from scratch. Input resolution, augmentation, optimizer, batch size, detector, losses, and evaluation are identical.

Backbone GFLOPs-F ↓ GFLOPs-B ↓ GFLOPs-O ↓ AP50 ↑ APsmall ↑
DINOv3 ViT-S+/16 23.61 448.71 472.32 0.768 0.411
BiHash-DINOv3 ViT-S+/16 25.96 142.25 168.21 0.808 0.527

Table A. PANDA results with the same DINOv3 checkpoint, detector, and training protocol.

Backbone Latency (ms) ↓ FPS ↑
DINOv3 ViT-S+/16 13,280 0.075
BiHash-DINOv3 ViT-S+/16 5,780 0.173

Table B. PANDA wall-clock efficiency on one RTX 4090.

The 11.6-point APsmall gain supports foreground-focused compression and missed-object compensation.

Why is retaining the top 50% of key-value pairs effective?

We separate query-dependent selection from its 50% budget. Following HashAttention [2], KV pair ii contributes to query qq by

cqi=αqi∥vi∥2,αqi=exp⁡(q⊤ki/d)∑jexp⁡(q⊤kj/d).c_{qi}=\alpha_{qi}\lVert v_i\rVert_2, \qquad \alpha_{qi}= \frac{\exp(q^\top k_i/\sqrt d)} {\sum_j\exp(q^\top k_j/\sqrt d)}.

Ranking by cqic_{qi} is a maximum-inner-product search, which can be reduced to cosine search and approximated with compact binary signatures. This motivates our separate learned query/key Hamming mappings. Following dynamic/static and conditional sparsity [12,13], let mi(q;θ)∈0,1m_i(q;\theta)\in\\{0,1\\} be the query-dependent mask at retention ρ\rho:

min⁡θ;E(x,z)∼D[ℓ(f(x;m(q;θ)),z)]s.t.Ex∼D[1N∑i=1Nmi(q;θ)]≤ρ.\min_\theta\\; \mathbb E_{(x,z)\sim\mathcal D} \bigl[\ell(f(x;m(q;\theta)),z)\bigr] \quad \text{s.t.}\quad \mathbb E_{x\sim\mathcal D} \left[\frac1N\sum_{i=1}^{N}m_i(q;\theta)\right]\le\rho .

Definition 1 (dynamic Hamming attention). For binary codes bQ(q),bK(ki)∈−1,+1hb_Q(q),b_K(k_i)\in\\{-1,+1\\}^{h},

Sρ(q)=arg⁡min⁡∣S∣=⌊ρN⌋∑i∈SdH!(bQ(q),bK(ki)),aρ(q)=∑i∈Sρ(q)αqi,S_\rho(q)= \underset{|S|=\lfloor\rho N\rfloor}{\arg\min} \sum_{i\in S}d_H\\!\left(b_Q(q),b_K(k_i)\right), \qquad a_\rho(q)=\sum_{i\in S_\rho(q)}\alpha_{qi},
yρ(q)=1aρ(q)∑i∈Sρ(q)αqivi.y_\rho(q)= \frac{1}{a_\rho(q)} \sum_{i\in S_\rho(q)}\alpha_{qi}v_i .

Definition 2 (static attention). A static layer uses one query-independent set TT; at equal budget, ∣T∣=⌊ρN⌋|T|=\lfloor\rho N\rfloor.

We use three standard assumptions adapted to attention. A1 (boundedness): ∥vi∥2≤V\lVert v_i\rVert_2\le V, and the downstream loss is LL-Lipschitz in the attention output. A2 (concentration): for Hamming score sqi=−dH(⋅,⋅)s_{qi}=-d_H(\cdot,\cdot) and a monotone map gg, errors sqi−g(cqi)s_{qi}-g(c_{qi}) are sub-Gaussian and their pairwise differences are 2σ\sqrt2\sigma-sub-Gaussian. A3 (task sign): GT-overlapping keys carry positive task utility, while selected background contributes noise or negative utility after balancing. Under A2, for Δij=g(cqi)−g(cqj)>0\Delta_{ij}=g(c_{qi})-g(c_{qj})>0,

Pr⁡[sqi≤sqj]≤exp⁡!(−Δij2/(4σ2)).\Pr[s_{qi}\le s_{qj}] \le \exp\\!\left(-\Delta_{ij}^2/(4\sigma^2)\right).

Proposition 1 (attention approximation). For dense output y(q)=∑iαqiviy(q)=\sum_i\alpha_{qi}v_i,

∥y(q)−yρ(q)∥2≤2V(1−aρ(q)),∣Δℓ∣≤2LV(1−aρ(q)).\lVert y(q)-y_\rho(q)\rVert_2 \le 2V\bigl(1-a_\rho(q)\bigr), \qquad |\Delta\ell| \le 2LV\bigl(1-a_\rho(q)\bigr).

To see the bound, split the dense sum into retained and discarded terms. Renormalization changes the retained term by at most V(1−aρ)V(1-a_\rho), and the discarded term has norm at most V(1−aρ)V(1-a_\rho). Thus, error depends on retained attention mass rather than token count; Hamming routing is effective when a small query-specific set preserves large mass.

Proposition 2 (dynamic-static gap). Let k=⌊ρN⌋k=\lfloor\rho N\rfloor, pi=Pr⁡[i∈Sρ(q)]p_i=\Pr[i\in S_\rho(q)], and p(1)≥⋯≥p(N)p_{(1)}\ge\cdots\ge p_{(N)}. Any static TT, ∣T∣=k|T|=k, satisfies

Eq![∣Sρ(q)∖T∣]=k−∑i∈Tpi≥k−∑j=1kp(j)≡Δk.\mathbb E_q\\!\left[|S_\rho(q)\setminus T|\right] =k-\sum_{i\in T}p_i \ge k-\sum_{j=1}^{k}p_{(j)} \equiv\Delta_k .

The equality follows from ∣Sρ(q)∣=k|S_\rho(q)|=k and linearity of expectation; selecting the kk largest pip_i maximizes the covered probability mass. Unless the same kk keys serve every query (Δk=0\Delta_k=0), every equal-budget static set misses query-specific interactions. To reduce its expected miss count below ϵ\epsilon, a static layer needs

r_\epsilon= \min\left\\{ r:\sum_{j=1}^{r}p_{(j)}\ge k-\epsilon \right\\}

keys. If ϵ<Δk\epsilon<\Delta_k, then rϵ>kr_\epsilon>k: the static layer must spend more computation to cover the union represented by kk dynamic keys per query. For MM independent queries, with ΔT(q)=∣Sρ(q)∖T∣\Delta_T(q)=|S_\rho(q)\setminus T| and sample mean Δ^T\widehat\Delta_T,

Pr⁡![∣Δ^T−EΔT∣≥ϵ]≤2exp⁡!(−2Mϵ2/k2).\Pr\\!\left[ \left|\widehat\Delta_T-\mathbb E\Delta_T\right|\ge\epsilon \right] \le 2\exp\\!\left(-2M\epsilon^2/k^2\right).

Thus, the empirical coverage gap concentrates around its expectation. This formalizes why a query-dependent mask represents diverse interactions more efficiently than one fixed KV subset. BinaryFormer [3] concerns numerical quantization, not this dynamic top-kk property.

These results justify dynamic selection, but do not imply a universal ρ\rho. To analyze the ratio, we project GT boxes onto each feature map: keys whose spatial cells overlap any GT box form foreground set FF, and all others form background set BB. Define

CF(q)=∑i∈Fcqi,Dmiss(ρ,q)=∑i∈F∖Sρ(q)cqiCF(q),C_F(q)=\sum_{i\in F}c_{qi},\qquad D_{\mathrm{miss}}(\rho,q)= \frac{\sum_{i\in F\setminus S_\rho(q)}c_{qi}}{C_F(q)},
Dbg(ρ,q)=β∑i∈B∩Sρ(q)cqiCF(q),β=∣F∣∣B∣.D_{\mathrm{bg}}(\rho,q)= \frac{\beta\sum_{i\in B\cap S_\rho(q)}c_{qi}}{C_F(q)}, \qquad \beta=\frac{|F|}{|B|}.

Our normalized GT-aware foreground utility is exactly

RqFG(ρ)=100[1−Dmiss(ρ,q)−Dbg(ρ,q)].R_q^{\mathrm{FG}}(\rho) =100\left[ 1-D_{\mathrm{miss}}(\rho,q)-D_{\mathrm{bg}}(\rho,q) \right].

The ideal set containing all foreground and no background keys scores 100%. Increasing ρ\rho monotonically decreases missed foreground DmissD_{\mathrm{miss}} but increases admitted background DbgD_{\mathrm{bg}}; utility therefore need not grow with retention. Combining Proposition 1 with compute C(ρ)\mathcal C(\rho) gives

J(ρ)=2LV,E[1−aρ(q)]+λ,E[Dmiss(ρ,q)+Dbg(ρ,q)]+η,C(ρ).\mathcal J(\rho)= 2LV\\,\mathbb E[1-a_\rho(q)] +\lambda\\,\mathbb E[ D_{\mathrm{miss}}(\rho,q)+D_{\mathrm{bg}}(\rho,q)] +\eta\\,\mathcal C(\rho).

Dense attention is used only offline to obtain αqi\alpha_{qi}. On the complete PANDA test set, we evaluate all queries, heads, and HashAttention blocks in every selected window overlapping a GT box, then average over all such foreground windows rather than a sampled subset:

KV retention Mean GT-aware foreground utility (%) ↑ Compression-branch GFLOPs ↓ AP50 ↑
20% 74.8 16.97 0.803
50% (HashAttention) 86.0 38.12 0.810
80% 70.6 60.28 0.799
100% (dense attention) 62.1 80.11 0.797

Table C. Effect of the KV-retention ratio on GT-aware foreground utility, compression cost, and PANDA detection accuracy.

Normalized distortion is 25.2%, 14.0%, 29.4%, and 37.9% at 20%, 50%, 80%, and 100%. At 20%, omitted foreground dominates; beyond 50%, additional background dominates. The 80% and 100% settings also lower AP50 while increasing computation. Thus, 50% empirically minimizes foreground omission, background interference, and cost; it is not a distribution-free constant.

Does BiHashFormer generalize to semantic segmentation?

We evaluate on ADE20K [4] (150 classes; 20,210/2,000 train/val images) using the standard MMSegmentation UPerNet [5] 160k protocol: ImageNet-1K initialization, 512×512 crops, batch 16, AdamW (6×10−56\times10^{-5}, weight decay 0.01), 1,500-step warm-up, polynomial decay, and random resize/crop/flip/photometric augmentation. FLOPs use 512×2048 inputs; SS/MS mIoU are reported.

Backbone FLOPs (G) ↓ mIoU SS ↑ mIoU MS ↑
SW-tiny [6] 948 49.22 50.06
ConvNeXt-T [7] 939 46.0 46.7
SLaK-T [8] 936 47.6 —
UniRepLKNet-T [9] 946 48.6 49.1
Swin-T [10] 945 44.5 45.8
InternImage-T [11] 944 47.9 48.1
BiHashFormer 477 49.72 50.28

Table D. ADE20K validation under the UPerNet 160k protocol. Baselines follow ShiftwiseConv Table 5 [6].

BiHashFormer reaches 49.72/50.28 SS/MS mIoU: +5.22/+4.48 over Swin-T with 49.5% fewer FLOPs, and +0.50/+0.22 over SW-tiny with 49.7% fewer FLOPs.

References

  • [1] Siméoni et al., DINOv3, 2025.
  • [2] Desai et al., HashAttention, ICML 2025.
  • [3] Wang et al., BinaryFormer, IEEE TII 2024.
  • [4] Zhou et al., ADE20K, IJCV 2019.
  • [5] Xiao et al., UPerNet, ECCV 2018.
  • [6] Li et al., ShiftwiseConv, CVPR 2025.
  • [7] Liu et al., ConvNeXt, CVPR 2022.
  • [8] Liu et al., SLaK, ICLR 2023.
  • [9] Ding et al., UniRepLKNet, CVPR 2024.
  • [10] Liu et al., Swin Transformer, ICCV 2021.
  • [11] Wang et al., InternImage, CVPR 2023.
  • [12] Li et al., ThinFormer, IJCAI-ECAI 2026.
  • [13] Hoefler et al., Sparsity in Deep Learning, JMLR 2021.

From OpenReview, CC BY 4.0. Authors as signed there; shown unedited.

Missing a submission?

Loading the discussion…