{"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/unified-negative-pair-generation-toward-well","title":"Unified Negative Pair Generation toward Well-discriminative Feature Space for Face Recognition","arxiv_id":"2203.11593","date":"2022-03-22","proceeding":null,"authors":["Junuk Jung","Seonhoon Lee","Heung-Seon Oh","Yongjun Park","Joochan Park","Sungbin Son"],"abstract":"The goal of face recognition (FR) can be viewed as a pair similarity optimization problem, maximizing a similarity set $\\mathcal{S}^p$ over positive pairs, while minimizing similarity set $\\mathcal{S}^n$ over negative pairs. Ideally, it is expected that FR models form a well-discriminative feature space (WDFS) that satisfies $\\inf{\\mathcal{S}^p} > \\sup{\\mathcal{S}^n}$. With regard to WDFS, the existing deep feature learning paradigms (i.e., metric and classification losses) can be expressed as a unified perspective on different pair generation (PG) strategies. Unfortunately, in the metric loss (ML), it is infeasible to generate negative pairs taking all classes into account in each iteration because of the limited mini-batch size. In contrast, in classification loss (CL), it is difficult to generate extremely hard negative pairs owing to the convergence of the class weight vectors to their center. This leads to a mismatch between the two similarity distributions of the sampled pairs and all negative pairs. Thus, this paper proposes a unified negative pair generation (UNPG) by combining two PG strategies (i.e., MLPG and CLPG) from a unified perspective to alleviate the mismatch. UNPG introduces useful information about negative pairs using MLPG to overcome the CLPG deficiency. Moreover, it includes filtering the similarities of noisy negative pairs to guarantee reliable convergence and improved performance. Exhaustive experiments show the superiority of UNPG by achieving state-of-the-art performance across recent loss functions on public benchmark datasets. Our code and pretrained models are publicly available.","url_abs":"https://arxiv.org/abs/2203.11593v2","url_pdf":"https://arxiv.org/pdf/2203.11593v2.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":"unified-negative-pair-generation-toward-well","repo_url":"https://github.com/jung-jun-uk/unpg","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"pytorch","reach":{"status":"ok","spdx":"Apache-2.0"}},{"paper_slug":"unified-negative-pair-generation-toward-well","repo_url":"https://github.com/tomas-gajarsky/facetorch","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"face-identification","task_name":"Face Identification"},{"task_slug":"face-recognition","task_name":"Face Recognition"},{"task_slug":"face-verification","task_name":"Face Verification"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/face-identification-on-megaface","task":"Face Identification","dataset":"MegaFace","model":"Cos+UNPG","rank_in_archive_order":1,"of":13,"metrics":{"Accuracy":"99.27%"},"uses_additional_data":false},{"leaderboard":"/sota/face-identification-on-megaface","task":"Face Identification","dataset":"MegaFace","model":"Arc+UNPG","rank_in_archive_order":3,"of":13,"metrics":{"Accuracy":"98.82%"},"uses_additional_data":false},{"leaderboard":"/sota/face-identification-on-megaface","task":"Face Identification","dataset":"MegaFace","model":"Mag+UNPG","rank_in_archive_order":7,"of":13,"metrics":{"Accuracy":"98.03%"},"uses_additional_data":false},{"leaderboard":"/sota/face-verification-on-ijb-b","task":"Face Verification","dataset":"IJB-B","model":"Arc+UNPG","rank_in_archive_order":2,"of":12,"metrics":{"TAR @ FAR=0.001":"96.6","TAR @ FAR=0.01":"97.7%","TAR@FAR=0.0001":"95.04"},"uses_additional_data":false},{"leaderboard":"/sota/face-verification-on-ijb-b","task":"Face Verification","dataset":"IJB-B","model":"Mag+UNPG","rank_in_archive_order":3,"of":12,"metrics":{"TAR @ FAR=0.001":"96.5","TAR @ FAR=0.01":"97.63%","TAR@FAR=0.0001":"95.21"},"uses_additional_data":false},{"leaderboard":"/sota/face-verification-on-ijb-b","task":"Face Verification","dataset":"IJB-B","model":"Cos+UNPG","rank_in_archive_order":4,"of":12,"metrics":{"TAR @ FAR=0.001":"96.5","TAR @ FAR=0.01":"97.36%","TAR@FAR=0.0001":"94.99"},"uses_additional_data":false},{"leaderboard":"/sota/face-verification-on-ijb-c","task":"Face Verification","dataset":"IJB-C","model":"Mag+UNPG","rank_in_archive_order":7,"of":26,"metrics":{"TAR @ FAR=1e-5":"94.7%"},"uses_additional_data":false},{"leaderboard":"/sota/face-verification-on-ijb-c","task":"Face Verification","dataset":"IJB-C","model":"Cos+UNPG","rank_in_archive_order":8,"of":26,"metrics":{"TAR @ FAR=1e-3":"97.57","TAR @ FAR=1e-4":"96.38%","TAR @ FAR=1e-5":"94.47%","model":"R100","training dataset":"MS1MV2"},"uses_additional_data":false},{"leaderboard":"/sota/face-verification-on-ijb-c","task":"Face Verification","dataset":"IJB-C","model":"Arc+UNPG","rank_in_archive_order":19,"of":26,"metrics":{"TAR @ FAR=1e-3":"97.51","TAR @ FAR=1e-4":"96.33%"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2203.11593","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2203.11593"}},"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/tomas-gajarsky/facetorch","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/jung-jun-uk/unpg","reach":{"status":"ok","spdx":"Apache-2.0"}}],"summary":{"ran_draft_wrong":2,"unverified":12},"by_repo_kind":{"official":{"samples":14,"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":"158bf4c3a5f11f04","entry":"conv1x1","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"recognition/models/iresnet.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/recognition/models/iresnet.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"158bf4c3a5f11f04"}},{"code_sha256_prefix":"29df79c9fdb0cee8","entry":"conv3x3","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"recognition/models/iresnet.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/recognition/models/iresnet.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"29df79c9fdb0cee8"}},{"code_sha256_prefix":"d5ef2a1cd275f515","entry":"box_and_whisker_algorithm","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"recognition/models/build.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/recognition/models/build.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"d5ef2a1cd275f515"}},{"code_sha256_prefix":"6f437f153ac1b10c","entry":"build_models","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"recognition/models/build.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/recognition/models/build.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"6f437f153ac1b10c"}},{"code_sha256_prefix":"da3669dabcdd0326","entry":"check_keys","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"detection/retinaface/loader.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/detection/retinaface/loader.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"da3669dabcdd0326"}},{"code_sha256_prefix":"f5414e78ff7a815f","entry":"conv_bn","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"detection/retinaface/models/net.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/detection/retinaface/models/net.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"f5414e78ff7a815f"}},{"code_sha256_prefix":"bb07aa213e6aacc9","entry":"conv_bn1X1","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"detection/retinaface/models/net.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/detection/retinaface/models/net.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"bb07aa213e6aacc9"}},{"code_sha256_prefix":"aacb8f654f54d534","entry":"conv_bn_no_relu","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"detection/retinaface/models/net.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/detection/retinaface/models/net.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"aacb8f654f54d534"}},{"code_sha256_prefix":"1797ec521871130c","entry":"convert_label_to_similarity","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"recognition/models/build.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/recognition/models/build.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"1797ec521871130c"}},{"code_sha256_prefix":"8a6f28d59833cee6","entry":"get_affine_transform_matrix","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"detection/alignment.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/detection/alignment.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"8a6f28d59833cee6"}},{"code_sha256_prefix":"8e88e8cdf0c6402f","entry":"get_reference_facial_points","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"detection/alignment.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/detection/alignment.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"8e88e8cdf0c6402f"}},{"code_sha256_prefix":"297f7fbb6b24d3d7","entry":"iresnet","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"recognition/models/iresnet.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/recognition/models/iresnet.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"297f7fbb6b24d3d7"}},{"code_sha256_prefix":"fdbe70b1f0ff1936","entry":"remove_prefix","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"detection/retinaface/loader.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/detection/retinaface/loader.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"fdbe70b1f0ff1936"}},{"code_sha256_prefix":"a07ddf14857db52f","entry":"warp_and_crop_face","repo":"jung-jun-uk/unpg","repo_kind":"official","path":"detection/alignment.py","file_url":"https://github.com/jung-jun-uk/unpg/blob/HEAD/detection/alignment.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"a07ddf14857db52f"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}