{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/cross-modal-retrieval-with-querybank","title":"Cross Modal Retrieval with Querybank Normalisation","arxiv_id":"2112.12777","date":"2021-12-23","proceeding":"CVPR 2022 1","authors":["Simion-Vlad Bogolin","Ioana Croitoru","Hailin Jin","Yang Liu","Samuel Albanie"],"abstract":"Profiting from large-scale training datasets, advances in neural architecture design and efficient inference, joint embeddings have become the dominant approach for tackling cross-modal retrieval. In this work we first show that, despite their effectiveness, state-of-the-art joint embeddings suffer significantly from the longstanding \"hubness problem\" in which a small number of gallery embeddings form the nearest neighbours of many queries. Drawing inspiration from the NLP literature, we formulate a simple but effective framework called Querybank Normalisation (QB-Norm) that re-normalises query similarities to account for hubs in the embedding space. QB-Norm improves retrieval performance without requiring retraining. Differently from prior work, we show that QB-Norm works effectively without concurrent access to any test set queries. Within the QB-Norm framework, we also propose a novel similarity normalisation method, the Dynamic Inverted Softmax, that is significantly more robust than existing approaches. We showcase QB-Norm across a range of cross modal retrieval models and benchmarks where it consistently enhances strong baselines beyond the state of the art. Code is available at https://vladbogo.github.io/QB-Norm/.","url_abs":"https://arxiv.org/abs/2112.12777v3","url_pdf":"https://arxiv.org/pdf/2112.12777v3.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"cross-modal-retrieval-with-querybank","repo_url":"https://github.com/ioanacroi/qb-norm","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":0,"framework":"none","reach":null}],"tasks":[{"task_slug":"cross-modal-retrieval","task_name":"Cross-Modal Retrieval"},{"task_slug":"metric-learning","task_name":"Metric Learning"},{"task_slug":"retrieval","task_name":"Retrieval"},{"task_slug":"text-to-audio-retrieval","task_name":"Text to Audio Retrieval"},{"task_slug":"video-retrieval","task_name":"Video Retrieval"}],"methods":[{"method_slug":"softmax","method_name":"Softmax"}],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/metric-learning-on-stanford-online-products-1","task":"Metric Learning","dataset":"Stanford Online Products","model":"QB-Norm+RDML","rank_in_archive_order":30,"of":33,"metrics":{"R@1":"78.1"},"uses_additional_data":false},{"leaderboard":"/sota/text-to-audio-retrieval-on-audiocaps","task":"Text to Audio Retrieval","dataset":"AudioCaps","model":"QB-Norm+CE","rank_in_archive_order":7,"of":11,"metrics":{"R@1":"23.9","R@10":"71.6±0.4"},"uses_additional_data":false},{"leaderboard":"/sota/video-retrieval-on-didemo","task":"Video Retrieval","dataset":"DiDeMo","model":"QB-Norm+CLIP4Clip","rank_in_archive_order":33,"of":40,"metrics":{"text-to-video Median Rank":"2.0","text-to-video R@1":"43.5","text-to-video R@10":"80.9","text-to-video R@5":"71.4"},"uses_additional_data":true},{"leaderboard":"/sota/video-retrieval-on-lsmdc","task":"Video Retrieval","dataset":"LSMDC","model":"QB-Norm+CLIP4Clip","rank_in_archive_order":23,"of":38,"metrics":{"text-to-video Median Rank":"11.0","text-to-video R@1":"22.4","text-to-video R@10":"49.5","text-to-video R@5":"40.1"},"uses_additional_data":true},{"leaderboard":"/sota/video-retrieval-on-msr-vtt-1ka","task":"Video Retrieval","dataset":"MSR-VTT-1kA","model":"QB-Norm+CLIP2Video","rank_in_archive_order":29,"of":63,"metrics":{"text-to-video Median Rank":"2","text-to-video R@1":"47.2","text-to-video R@10":"83.0","text-to-video R@5":"73.0"},"uses_additional_data":true},{"leaderboard":"/sota/video-retrieval-on-msvd","task":"Video Retrieval","dataset":"MSVD","model":"QB-Norm+CLIP2Video","rank_in_archive_order":14,"of":24,"metrics":{"text-to-video Median Rank":"2.0","text-to-video R@1":"48.0","text-to-video R@10":"86.2","text-to-video R@5":"77.9"},"uses_additional_data":true},{"leaderboard":"/sota/video-retrieval-on-queryd","task":"Video Retrieval","dataset":"QuerYD","model":"QB-Norm+TT-CE+","rank_in_archive_order":5,"of":5,"metrics":{"text-to-video R@1":"15.1"},"uses_additional_data":false},{"leaderboard":"/sota/video-retrieval-on-vatex","task":"Video Retrieval","dataset":"VATEX","model":"QB-Norm+CLIP2Video","rank_in_archive_order":12,"of":13,"metrics":{"text-to-video R@1":"58.8","text-to-video R@10":"93.8"},"uses_additional_data":true}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2112.12777","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2112.12777"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/ioanacroi/qb-norm","reach":null}],"summary":{"ran_violates":1,"ran_draft_wrong":1,"unverified":1},"by_repo_kind":{"official":{"samples":3,"ran":2,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":0,"samples":[{"code_sha256_prefix":"a10186631d0894f1","entry":"get_index_to_normalize","repo":"ioanacroi/qb-norm","repo_kind":"official","path":"dynamic_inverted_softmax.py","file_url":"https://github.com/ioanacroi/qb-norm/blob/HEAD/dynamic_inverted_softmax.py","link_basis":"first_harvest_node","language":"python","status":"ran_violates","verification_level":1,"contract_check":"VIOLATES","metamorphic_tier":"invariant","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"a10186631d0894f1"}},{"code_sha256_prefix":"c47491c3f4b973fb","entry":"get_retrieved_videos","repo":"ioanacroi/qb-norm","repo_kind":"official","path":"dynamic_inverted_softmax.py","file_url":"https://github.com/ioanacroi/qb-norm/blob/HEAD/dynamic_inverted_softmax.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":"invariant","behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"c47491c3f4b973fb"}},{"code_sha256_prefix":"c5b7f779031151b1","entry":"qb_norm","repo":"ioanacroi/qb-norm","repo_kind":"official","path":"dynamic_inverted_softmax.py","file_url":"https://github.com/ioanacroi/qb-norm/blob/HEAD/dynamic_inverted_softmax.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"c5b7f779031151b1"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}