{"id":13776707,"url":"https://github.com/TeamGraphix/graphix","last_synced_at":"2025-05-11T10:31:12.992Z","repository":{"id":148571837,"uuid":"573466585","full_name":"TeamGraphix/graphix","owner":"TeamGraphix","description":"measurement-based quantum computing (MBQC) compiler and simulator","archived":false,"fork":false,"pushed_at":"2025-04-28T12:11:42.000Z","size":1683,"stargazers_count":75,"open_issues_count":47,"forks_count":21,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-04-28T13:33:50.642Z","etag":null,"topics":["graph-states","mbqc","quantum","quantum-computing","quantum-programming-language","unitaryhack"],"latest_commit_sha":null,"homepage":"https://graphix.readthedocs.io","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TeamGraphix.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":"CITATION.cff","codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2022-12-02T14:29:12.000Z","updated_at":"2025-04-28T12:11:45.000Z","dependencies_parsed_at":"2023-10-16T20:58:21.900Z","dependency_job_id":"131972fd-8908-47fe-97ae-44eb49547831","html_url":"https://github.com/TeamGraphix/graphix","commit_stats":null,"previous_names":[],"tags_count":22,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TeamGraphix%2Fgraphix","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TeamGraphix%2Fgraphix/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TeamGraphix%2Fgraphix/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TeamGraphix%2Fgraphix/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TeamGraphix","download_url":"https://codeload.github.com/TeamGraphix/graphix/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253551658,"owners_count":21926330,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["graph-states","mbqc","quantum","quantum-computing","quantum-programming-language","unitaryhack"],"created_at":"2024-08-03T18:00:31.862Z","updated_at":"2025-05-11T10:31:12.979Z","avatar_url":"https://github.com/TeamGraphix.png","language":"Python","funding_links":[],"categories":["Quantum simulators"],"sub_categories":[],"readme":"\u003cimg src=\"https://github.com/TeamGraphix/graphix/raw/master/docs/logo/black_with_name.png\" alt=\"logo\" width=\"550\"\u003e\n\n![PyPI](https://img.shields.io/pypi/v/graphix)\n![License](https://img.shields.io/github/license/TeamGraphix/graphix)\n![PyPI - Python Version](https://img.shields.io/pypi/pyversions/graphix)\n[![Downloads](https://static.pepy.tech/badge/graphix)](https://pepy.tech/project/graphix)\n[![Unitary Fund](https://img.shields.io/badge/Supported%20By-UNITARY%20FUND-brightgreen.svg)](https://unitary.fund/)\n[![DOI](https://zenodo.org/badge/573466585.svg)](https://zenodo.org/badge/latestdoi/573466585)\n[![CI](https://github.com/TeamGraphix/graphix/actions/workflows/ci.yml/badge.svg)](https://github.com/TeamGraphix/graphix/actions/workflows/ci.yml)\n[![codecov](https://codecov.io/gh/TeamGraphix/graphix/graph/badge.svg?token=E41MLUTYXU)](https://codecov.io/gh/TeamGraphix/graphix)\n[![Documentation Status](https://readthedocs.org/projects/graphix/badge/?version=latest)](https://graphix.readthedocs.io/en/latest/?badge=latest)\n[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)\n\n**Graphix** is a measurement-based quantum computing (MBQC) software package, featuring\n\n- the measurement calculus framework with integrated graphical rewrite rules for Pauli measurement preprocessing\n- circuit-to-pattern transpiler, graph-based deterministic pattern generator and manual pattern generation\n- flow, gflow and pauliflow finding tools and graph visualization based on flows (see below)\n- statevector, density matrix and tensornetwork pattern simulation backends\n- QPU interface and fusion network extraction tool\n\n## Installation\n\nInstall `graphix` with `pip`:\n\n```bash\npip install graphix\n```\n\nInstall together with device interface:\n\n```bash\npip install graphix[extra]\n```\n\nthis will install `graphix` and inteface for [IBMQ](https://github.com/TeamGraphix/graphix-ibmq) and [Perceval](https://github.com/TeamGraphix/graphix-perceval) to run MBQC patterns on superconducting and optical QPUs and their simulators.\n\n## Using graphix\n\n### generating pattern from a circuit\n\n```python\nfrom graphix import Circuit\n\ncircuit = Circuit(4)\ncircuit.h(0)\n...\npattern = circuit.transpile().pattern\npattern.draw_graph()\n```\n\n\u003cimg src=\"https://github.com/TeamGraphix/graphix/assets/33350509/de17c663-f607-44e2-945b-835f4082a940\" alt=\"graph_flow\" width=\"750\"\u003e\n\n\u003csmall\u003enote: this graph is generated from QAOA circuit, see [our example code](examples/qaoa.py). Arrows indicate the [_causal flow_](https://journals.aps.org/pra/abstract/10.1103/PhysRevA.74.052310) of MBQC and dashed lines are the other edges of the graph. the vertical dashed partitions and the labels 'l:n' below indicate the execution _layers_ or the order in the graph (measurements should happen from left to right, and nodes in the same layer can be measured simultaneously), based on the partial order associated with the (maximally-delayed) flow. \u003c/small\u003e\n\n### preprocessing Pauli measurements\n\n```python\npattern.perform_pauli_measurements()\npattern.draw_graph()\n```\n\n\u003cimg src=\"https://github.com/TeamGraphix/graphix/assets/33350509/3c30a4c9-f912-4a36-925f-2ff446a07c68\" alt=\"graph_gflow\" width=\"140\"\u003e\n\n\u003csmall\u003e(here, the graph is visualized based on [_generalized flow_](https://iopscience.iop.org/article/10.1088/1367-2630/9/8/250).)\u003c/small\u003e\n\n### simulating the pattern\n\n```python\nstate_out = pattern.simulate_pattern(backend=\"statevector\")\n```\n\n### and more..\n\n- See [demos](https://graphix.readthedocs.io/en/latest/gallery/index.html) showing other features of `graphix`.\n\n\n- Read the [tutorial](https://graphix.readthedocs.io/en/latest/tutorial.html) for more usage guides.\n\n- For theoretical background, read our quick introduction into [MBQC](https://graphix.readthedocs.io/en/latest/intro.html) and [LC-MBQC](https://graphix.readthedocs.io/en/latest/lc-mbqc.html).\n\n- Full API docs is [here](https://graphix.readthedocs.io/en/latest/references.html).\n\n## Citing\n\n\u003e Shinichi Sunami and Masato Fukushima, Graphix. (2023) \u003chttps://doi.org/10.5281/zenodo.7861382\u003e \n\n## Contributing\n\nWe use [GitHub issues](https://github.com/TeamGraphix/graphix/issues) for tracking feature requests and bug reports.\n\n## Discord Server\n\nPlease visit [Unitary Fund's Discord server](https://discord.com/servers/unitary-fund-764231928676089909), where you can find a channel for `graphix` to ask questions.\n\n## Core Contributors (alphabetical order)\n\n - Masato Fukushima (University of Tokyo, Fixstars Amplify)\n - Maxime Garnier (Inria Paris)\n - Thierry Martinez (Inria Paris)\n - Sora Shiratani (University of Tokyo, Fixstars Amplify)\n - Shinichi Sunami (University of Oxford)\n\n## Acknowledgements\n\nWe are proud to be supported by [unitary fund microgrant program](https://unitary.fund/grants.html).\n\n\u003cp\u003e\u003ca href=\"https://unitary.fund/grants.html\"\u003e\n\u003cimg src=\"https://user-images.githubusercontent.com/33350509/233384863-654485cf-b7d0-449e-8868-265c6fea2ced.png\" alt=\"unitary-fund\" width=\"150\"/\u003e\n\u003c/a\u003e\u003c/p\u003e\n\nSpecial thanks to Fixstars Amplify:\n\n\u003cp\u003e\u003ca href=\"https://amplify.fixstars.com/en/\"\u003e\n\u003cimg src=\"https://github.com/TeamGraphix/graphix/raw/master/docs/imgs/fam_logo.png\" alt=\"amplify\" width=\"200\"/\u003e\n\u003c/a\u003e\u003c/p\u003e\n\n## License\n\n[Apache License 2.0](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FTeamGraphix%2Fgraphix","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FTeamGraphix%2Fgraphix","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FTeamGraphix%2Fgraphix/lists"}