{"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/beyond-adversarial-training-min-max","title":"Adversarial Attack Generation Empowered by Min-Max Optimization","arxiv_id":"1906.03563","date":"2019-06-09","proceeding":"NeurIPS 2021 12","authors":["Jingkang Wang","Tianyun Zhang","Sijia Liu","Pin-Yu Chen","Jiacen Xu","Makan Fardad","Bo Li"],"abstract":"The worst-case training principle that minimizes the maximal adversarial loss, also known as adversarial training (AT), has shown to be a state-of-the-art approach for enhancing adversarial robustness. Nevertheless, min-max optimization beyond the purpose of AT has not been rigorously explored in the adversarial context. In this paper, we show how a general framework of min-max optimization over multiple domains can be leveraged to advance the design of different types of adversarial attacks. In particular, given a set of risk sources, minimizing the worst-case attack loss can be reformulated as a min-max problem by introducing domain weights that are maximized over the probability simplex of the domain set. We showcase this unified framework in three attack generation problems -- attacking model ensembles, devising universal perturbation under multiple inputs, and crafting attacks resilient to data transformations. Extensive experiments demonstrate that our approach leads to substantial attack improvement over the existing heuristic strategies as well as robustness improvement over state-of-the-art defense methods trained to be robust against multiple perturbation types. Furthermore, we find that the self-adjusted domain weights learned from our min-max framework can provide a holistic tool to explain the difficulty level of attack across domains. Code is available at https://github.com/wangjksjtu/minmax-adv.","url_abs":"https://arxiv.org/abs/1906.03563v3","url_pdf":"https://arxiv.org/pdf/1906.03563v3.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":"beyond-adversarial-training-min-max","repo_url":"https://github.com/wangjksjtu/minmax-adv","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"adversarial-attack","task_name":"Adversarial Attack"},{"task_slug":"adversarial-robustness","task_name":"Adversarial Robustness"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=1906.03563","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"1906.03563"}},"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/wangjksjtu/minmax-adv","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"ran_violates":1,"unverified":24},"by_repo_kind":{"official":{"samples":25,"ran":1,"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":"f017532fc389cbfe","entry":"str2bool","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/utils.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/utils.py","link_basis":"harvester_set","language":"python","status":"ran_violates","verification_level":1,"contract_check":"VIOLATES","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"f017532fc389cbfe"}},{"code_sha256_prefix":"936c00f08008f28d","entry":"cw_loss","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/attacks/minmax.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/attacks/minmax.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":"936c00f08008f28d"}},{"code_sha256_prefix":"213267d02b7820b8","entry":"evaluate","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/ens_attack.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/ens_attack.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":"213267d02b7820b8"}},{"code_sha256_prefix":"e607dfc06f869a5d","entry":"evaluate","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/trans_attack.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/trans_attack.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":"e607dfc06f869a5d"}},{"code_sha256_prefix":"247982bef8192964","entry":"evaluate","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/uni_attack.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/uni_attack.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":"247982bef8192964"}},{"code_sha256_prefix":"3ed5f9dfac95521e","entry":"fgm","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/attacks/fast_gradient.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/attacks/fast_gradient.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":"3ed5f9dfac95521e"}},{"code_sha256_prefix":"cd6509a1aade295c","entry":"fgmt","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/attacks/fast_gradient.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/attacks/fast_gradient.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":"cd6509a1aade295c"}},{"code_sha256_prefix":"f572fa6a26eff62d","entry":"get_interval","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/utils.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/utils.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":"f572fa6a26eff62d"}},{"code_sha256_prefix":"1d6df60e31ef00c5","entry":"get_model","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"pytorch/ens_attack.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/pytorch/ens_attack.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":"1d6df60e31ef00c5"}},{"code_sha256_prefix":"8d68ad2ec3439b5c","entry":"get_models","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/ens_attack.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/ens_attack.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":"8d68ad2ec3439b5c"}},{"code_sha256_prefix":"22ad888be68bfa1b","entry":"identity","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/utils.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/utils.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":"22ad888be68bfa1b"}},{"code_sha256_prefix":"83e7640948d1e7ea","entry":"image_folder_custom_label","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"pytorch/utils.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/pytorch/utils.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":"83e7640948d1e7ea"}},{"code_sha256_prefix":"e9de120c9fccad8d","entry":"l2_distance","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"pytorch/utils.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/pytorch/utils.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":"e9de120c9fccad8d"}},{"code_sha256_prefix":"ff4af237f270b266","entry":"make_ens_minmax","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/ens_attack.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/ens_attack.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":"ff4af237f270b266"}},{"code_sha256_prefix":"445cb63b8dd7ebb7","entry":"make_minmax_eot","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/trans_attack.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/trans_attack.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":"445cb63b8dd7ebb7"}},{"code_sha256_prefix":"232ff7a5fe7a603e","entry":"make_uni_minmax","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/uni_attack.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/uni_attack.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":"232ff7a5fe7a603e"}},{"code_sha256_prefix":"647f2c2e24c1966b","entry":"minmax_ens","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/attacks/minmax.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/attacks/minmax.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":"647f2c2e24c1966b"}},{"code_sha256_prefix":"8b57098358df5568","entry":"minmax_uni","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/attacks/minmax.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/attacks/minmax.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":"8b57098358df5568"}},{"code_sha256_prefix":"d8f5f464cb0707b2","entry":"modelA","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/models.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/models.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":"d8f5f464cb0707b2"}},{"code_sha256_prefix":"d9e789eb6c5505bc","entry":"modelB","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/models.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/models.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":"d9e789eb6c5505bc"}},{"code_sha256_prefix":"4e8ba12a7a587e76","entry":"modelC","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/models.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/models.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":"4e8ba12a7a587e76"}},{"code_sha256_prefix":"fed551f077ea431d","entry":"pgd","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/attacks/pgd.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/attacks/pgd.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":"fed551f077ea431d"}},{"code_sha256_prefix":"8bf68b71ad3a0000","entry":"proj_box","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/attacks/utils.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/attacks/utils.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":"8bf68b71ad3a0000"}},{"code_sha256_prefix":"24a5cabdc0b7b91c","entry":"proj_box_appro","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/attacks/utils.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/attacks/utils.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":"24a5cabdc0b7b91c"}},{"code_sha256_prefix":"964d413db2fdd014","entry":"proj_prob_simplex","repo":"wangjksjtu/minmax-adv","repo_kind":"official","path":"neurips21/attacks/utils.py","file_url":"https://github.com/wangjksjtu/minmax-adv/blob/HEAD/neurips21/attacks/utils.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":"964d413db2fdd014"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}