{"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/leveraging-hidden-positives-for-unsupervised","title":"Leveraging Hidden Positives for Unsupervised Semantic Segmentation","arxiv_id":"2303.15014","date":"2023-03-27","proceeding":"CVPR 2023 1","authors":["Hyun Seok Seong","WonJun Moon","SuBeen Lee","Jae-Pil Heo"],"abstract":"Dramatic demand for manpower to label pixel-level annotations triggered the advent of unsupervised semantic segmentation. Although the recent work employing the vision transformer (ViT) backbone shows exceptional performance, there is still a lack of consideration for task-specific training guidance and local semantic consistency. To tackle these issues, we leverage contrastive learning by excavating hidden positives to learn rich semantic relationships and ensure semantic consistency in local regions. Specifically, we first discover two types of global hidden positives, task-agnostic and task-specific ones for each anchor based on the feature similarities defined by a fixed pre-trained backbone and a segmentation head-in-training, respectively. A gradual increase in the contribution of the latter induces the model to capture task-specific semantic features. In addition, we introduce a gradient propagation strategy to learn semantic consistency between adjacent patches, under the inherent premise that nearby patches are highly likely to possess the same semantics. Specifically, we add the loss propagating to local hidden positives, semantically similar nearby patches, in proportion to the predefined similarity scores. With these training schemes, our proposed method achieves new state-of-the-art (SOTA) results in COCO-stuff, Cityscapes, and Potsdam-3 datasets. Our code is available at: https://github.com/hynnsk/HP.","url_abs":"https://arxiv.org/abs/2303.15014v1","url_pdf":"https://arxiv.org/pdf/2303.15014v1.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":"leveraging-hidden-positives-for-unsupervised","repo_url":"https://github.com/hynnsk/hp","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"contrastive-learning","task_name":"Contrastive Learning"},{"task_slug":"semantic-segmentation","task_name":"Semantic Segmentation"},{"task_slug":"unsupervised-semantic-segmentation","task_name":"Unsupervised Semantic Segmentation"}],"methods":[{"method_slug":"attention","method_name":"Attention"},{"method_slug":"contrastive-learning","method_name":"Contrastive Learning"},{"method_slug":"dense-connections","method_name":"Dense Connections"},{"method_slug":"layer-normalization","method_name":"Layer Normalization"},{"method_slug":"linear-layer","method_name":"Linear Layer"},{"method_slug":"multi-head-attention","method_name":"Multi-Head Attention"},{"method_slug":"residual-connection","method_name":"Residual Connection"},{"method_slug":"softmax","method_name":"Softmax"},{"method_slug":"vision-transformer","method_name":"Vision Transformer"}],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/unsupervised-semantic-segmentation-on-coco-7","task":"Unsupervised Semantic Segmentation","dataset":"COCO-Stuff-27","model":"HP (ViT-S/8)","rank_in_archive_order":16,"of":29,"metrics":{"Clustering [Accuracy]":"57.2","Clustering [mIoU]":"24.6","Linear Classifier [Accuracy]":"75.6","Linear Classifier [mIoU]":"42.7"},"uses_additional_data":false},{"leaderboard":"/sota/unsupervised-semantic-segmentation-on-coco-7","task":"Unsupervised Semantic Segmentation","dataset":"COCO-Stuff-27","model":"HP (ViT-S/16)","rank_in_archive_order":18,"of":29,"metrics":{"Clustering [Accuracy]":"54.5","Clustering [mIoU]":"24.3","Linear Classifier [Accuracy]":"74.1","Linear Classifier [mIoU]":"39.1"},"uses_additional_data":false},{"leaderboard":"/sota/unsupervised-semantic-segmentation-on","task":"Unsupervised Semantic Segmentation","dataset":"Cityscapes test","model":"HP","rank_in_archive_order":9,"of":14,"metrics":{"Accuracy":"80.1","mIoU":"18.4"},"uses_additional_data":false},{"leaderboard":"/sota/unsupervised-semantic-segmentation-on-potsdam-1","task":"Unsupervised Semantic Segmentation","dataset":"Potsdam-3","model":"HP","rank_in_archive_order":3,"of":8,"metrics":{"Accuracy":"82.4"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2303.15014","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2303.15014"}},"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/hynnsk/hp","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"deterministic:regex_extraction","url":"https://github.com/hynnsk/HP","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"ran":1,"unverified":2},"by_repo_kind":{"official":{"samples":3,"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":"ffa50103d0b8fac8","entry":"ClusterLookup","repo":"hynnsk/HP","repo_kind":"official","path":"model/STEGO.py","file_url":"https://github.com/hynnsk/HP/blob/HEAD/model/STEGO.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"ffa50103d0b8fac8"}},{"code_sha256_prefix":"9b53dfa39ff1e25a","entry":"DinoFeaturizer","repo":"hynnsk/HP","repo_kind":"official","path":"model/STEGO.py","file_url":"https://github.com/hynnsk/HP/blob/HEAD/model/STEGO.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":"9b53dfa39ff1e25a"}},{"code_sha256_prefix":"f1680b66d62cb44d","entry":"STEGOmodel","repo":"hynnsk/HP","repo_kind":"official","path":"model/STEGO.py","file_url":"https://github.com/hynnsk/HP/blob/HEAD/model/STEGO.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":"f1680b66d62cb44d"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}