{"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/understanding-the-vulnerability-of-clip-to","title":"Understanding the Vulnerability of CLIP to Image Compression","arxiv_id":"2311.14029","date":"2023-11-23","proceeding":null,"authors":["Cangxiong Chen","Vinay P. Namboodiri","Julian Padget"],"abstract":"CLIP is a widely used foundational vision-language model that is used for zero-shot image recognition and other image-text alignment tasks. We demonstrate that CLIP is vulnerable to change in image quality under compression. This surprising result is further analysed using an attribution method-Integrated Gradients. Using this attribution method, we are able to better understand both quantitatively and qualitatively exactly the nature in which the compression affects the zero-shot recognition accuracy of this model. We evaluate this extensively on CIFAR-10 and STL-10. Our work provides the basis to understand this vulnerability of CLIP and can help us develop more effective methods to improve the robustness of CLIP and other vision-language models.","url_abs":"https://arxiv.org/abs/2311.14029v1","url_pdf":"https://arxiv.org/pdf/2311.14029v1.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":"understanding-the-vulnerability-of-clip-to","repo_url":"https://github.com/CangxiongChen/understanding_CLIP_vulnerability","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok"}}],"tasks":[{"task_slug":"image-compression","task_name":"Image Compression"},{"task_slug":"language-modeling","task_name":"Language Modeling"},{"task_slug":"language-modelling","task_name":"Language Modelling"},{"task_slug":"zero-shot-learning","task_name":"Zero-Shot Learning"}],"methods":[{"method_slug":"clip","method_name":"CLIP"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":null,"atlas_url":"https://app.syntology.ai/?focus=2311.14029","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2311.14029"}},"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/CangxiongChen/understanding_CLIP_vulnerability","reach":{"status":"ok"}}],"summary":{"ran":5,"unverified":1},"by_repo_kind":{"official":{"samples":6,"ran":5,"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":6,"samples":[{"code_sha256_prefix":"807806873c183405","entry":"ComputeThresholdByTopPercentage","repo":"CangxiongChen/understanding_CLIP_vulnerability","repo_kind":"official","path":"visualization_lib.py","file_url":"https://github.com/CangxiongChen/understanding_CLIP_vulnerability/blob/HEAD/visualization_lib.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"807806873c183405"}},{"code_sha256_prefix":"95959711bce8ac8d","entry":"ConvertToGrayscale","repo":"CangxiongChen/understanding_CLIP_vulnerability","repo_kind":"official","path":"visualization_lib.py","file_url":"https://github.com/CangxiongChen/understanding_CLIP_vulnerability/blob/HEAD/visualization_lib.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"95959711bce8ac8d"}},{"code_sha256_prefix":"b77b30a203a1f030","entry":"Polarity","repo":"CangxiongChen/understanding_CLIP_vulnerability","repo_kind":"official","path":"visualization_lib.py","file_url":"https://github.com/CangxiongChen/understanding_CLIP_vulnerability/blob/HEAD/visualization_lib.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"b77b30a203a1f030"}},{"code_sha256_prefix":"6016869bd0e6f65b","entry":"predictions_and_gradients","repo":"CangxiongChen/understanding_CLIP_vulnerability","repo_kind":"official","path":"compute_IG.py","file_url":"https://github.com/CangxiongChen/understanding_CLIP_vulnerability/blob/HEAD/compute_IG.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"6016869bd0e6f65b"}},{"code_sha256_prefix":"12f33442cfbdec4b","entry":"read_txt_to_list","repo":"CangxiongChen/understanding_CLIP_vulnerability","repo_kind":"official","path":"compute_IG.py","file_url":"https://github.com/CangxiongChen/understanding_CLIP_vulnerability/blob/HEAD/compute_IG.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"12f33442cfbdec4b"}},{"code_sha256_prefix":"6224194f56968bca","entry":"integrated_gradients","repo":"CangxiongChen/understanding_CLIP_vulnerability","repo_kind":"official","path":"compute_IG.py","file_url":"https://github.com/CangxiongChen/understanding_CLIP_vulnerability/blob/HEAD/compute_IG.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"6224194f56968bca"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}