{"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/lazyiter-a-fast-algorithm-for-counting-markov","title":"LazyIter: A Fast Algorithm for Counting Markov Equivalent DAGs and Designing Experiments","arxiv_id":"2006.09670","date":"2020-06-17","proceeding":"ICML 2020 1","authors":["Ali AhmadiTeshnizi","Saber Salehkaleybar","Negar Kiyavash"],"abstract":"The causal relationships among a set of random variables are commonly represented by a Directed Acyclic Graph (DAG), where there is a directed edge from variable $X$ to variable $Y$ if $X$ is a direct cause of $Y$. From the purely observational data, the true causal graph can be identified up to a Markov Equivalence Class (MEC), which is a set of DAGs with the same conditional independencies between the variables. The size of an MEC is a measure of complexity for recovering the true causal graph by performing interventions. We propose a method for efficient iteration over possible MECs given intervention results. We utilize the proposed method for computing MEC sizes and experiment design in active and passive learning settings. Compared to previous work for computing the size of MEC, our proposed algorithm reduces the time complexity by a factor of $O(n)$ for sparse graphs where $n$ is the number of variables in the system. Additionally, integrating our approach with dynamic programming, we design an optimal algorithm for passive experiment design. Experimental results show that our proposed algorithms for both computing the size of MEC and experiment design outperform the state of the art.","url_abs":"https://arxiv.org/abs/2006.09670v1","url_pdf":"https://arxiv.org/pdf/2006.09670v1.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":"lazyiter-a-fast-algorithm-for-counting-markov","repo_url":"https://github.com/teshnizi/LazyIter","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":0,"framework":"none","reach":null}],"tasks":[],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2006.09670","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2006.09670"}},"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/teshnizi/LazyIter","reach":null}],"summary":{"ran_draft_wrong":3,"unverified":2},"by_repo_kind":{"official":{"samples":5,"ran":3,"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":"86326f9ce0e47d77","entry":"bfs_optimized","repo":"teshnizi/LazyIter","repo_kind":"official","path":"LazyIter/count.py","file_url":"https://github.com/teshnizi/LazyIter/blob/HEAD/LazyIter/count.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"86326f9ce0e47d77"}},{"code_sha256_prefix":"89bdaac3861e7e85","entry":"separate_graph","repo":"teshnizi/LazyIter","repo_kind":"official","path":"LazyIter/count.py","file_url":"https://github.com/teshnizi/LazyIter/blob/HEAD/LazyIter/count.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"89bdaac3861e7e85"}},{"code_sha256_prefix":"8564ec984cbba220","entry":"set_root_optimized","repo":"teshnizi/LazyIter","repo_kind":"official","path":"LazyIter/count.py","file_url":"https://github.com/teshnizi/LazyIter/blob/HEAD/LazyIter/count.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"8564ec984cbba220"}},{"code_sha256_prefix":"c2f44d1f3eab678b","entry":"count_iterate_optimized","repo":"teshnizi/LazyIter","repo_kind":"official","path":"LazyIter/count.py","file_url":"https://github.com/teshnizi/LazyIter/blob/HEAD/LazyIter/count.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":"c2f44d1f3eab678b"}},{"code_sha256_prefix":"8133b7802d39c5b5","entry":"lazy_count","repo":"teshnizi/LazyIter","repo_kind":"official","path":"LazyIter/count.py","file_url":"https://github.com/teshnizi/LazyIter/blob/HEAD/LazyIter/count.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":"8133b7802d39c5b5"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}