{"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/an-empirical-study-of-graph-contrastive","title":"An Empirical Study of Graph Contrastive Learning","arxiv_id":"2109.01116","date":"2021-09-02","proceeding":null,"authors":["Yanqiao Zhu","Yichen Xu","Qiang Liu","Shu Wu"],"abstract":"Graph Contrastive Learning (GCL) establishes a new paradigm for learning graph representations without human annotations. Although remarkable progress has been witnessed recently, the success behind GCL is still left somewhat mysterious. In this work, we first identify several critical design considerations within a general GCL paradigm, including augmentation functions, contrasting modes, contrastive objectives, and negative mining techniques. Then, to understand the interplay of different GCL components, we conduct extensive, controlled experiments over a set of benchmark tasks on datasets across various domains. Our empirical studies suggest a set of general receipts for effective GCL, e.g., simple topology augmentations that produce sparse graph views bring promising performance improvements; contrasting modes should be aligned with the granularities of end tasks. In addition, to foster future research and ease the implementation of GCL algorithms, we develop an easy-to-use library PyGCL, featuring modularized CL components, standardized evaluation, and experiment management. We envision this work to provide useful empirical evidence of effective GCL algorithms and offer several insights for future research.","url_abs":"https://arxiv.org/abs/2109.01116v2","url_pdf":"https://arxiv.org/pdf/2109.01116v2.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":"an-empirical-study-of-graph-contrastive","repo_url":"https://github.com/GraphCL/PyGCL","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"Apache-2.0"}},{"paper_slug":"an-empirical-study-of-graph-contrastive","repo_url":"https://github.com/maysambehmanesh/SGCL","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok"}},{"paper_slug":"an-empirical-study-of-graph-contrastive","repo_url":"https://github.com/pygcl/pygcl","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"graph-classification","task_name":"Graph Classification"},{"task_slug":"management","task_name":"Management"},{"task_slug":"node-classification","task_name":"Node Classification"}],"methods":[{"method_slug":"contrastive-learning","method_name":"Contrastive Learning"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":"https://syntology.ai/paper/2109.01116","atlas_url":"https://app.syntology.ai/?focus=2109.01116","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2109.01116"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-25T09:33:49+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/maysambehmanesh/SGCL","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/pygcl/pygcl","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/GraphCL/PyGCL","reach":{"status":"ok","spdx":"Apache-2.0"}}],"summary":{"ran_fixture":1,"unverified":3},"by_repo_kind":{"official":{"samples":3,"ran":0,"repositories":1},"listed":{"samples":1,"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":"f30b73fd238832a0","entry":"train","repo":"pygcl/pygcl","repo_kind":"listed","path":"examples/GraphCL.py","file_url":"https://github.com/pygcl/pygcl/blob/HEAD/examples/GraphCL.py","link_basis":"first_harvest_node","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"f30b73fd238832a0"}},{"code_sha256_prefix":"4e8c10013cc33f85","entry":"compute_supervised_masks","repo":"GraphCL/PyGCL","repo_kind":"official","path":"GCL/models/sampler.py","file_url":"https://github.com/GraphCL/PyGCL/blob/HEAD/GCL/models/sampler.py","link_basis":"first_harvest_node","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":"4e8c10013cc33f85"}},{"code_sha256_prefix":"71a5cdf26e3ee02d","entry":"similarity","repo":"GraphCL/PyGCL","repo_kind":"official","path":"GCL/losses/infonce.py","file_url":"https://github.com/GraphCL/PyGCL/blob/HEAD/GCL/losses/infonce.py","link_basis":"first_harvest_node","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":"71a5cdf26e3ee02d"}},{"code_sha256_prefix":"42b0b7ac1b0a1f92","entry":"tensor_similarity","repo":"GraphCL/PyGCL","repo_kind":"official","path":"GCL/losses/infonce.py","file_url":"https://github.com/GraphCL/PyGCL/blob/HEAD/GCL/losses/infonce.py","link_basis":"first_harvest_node","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":"42b0b7ac1b0a1f92"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}