Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More architecture options, some helper functions #105

Merged
merged 2 commits into from
Jan 21, 2023

Conversation

aborgna-q
Copy link
Contributor

This PR upstreams some of the changes implemented by @Aerylia in CQCL/pyzx while working for Cambridge Quantum.

This first PR adds 9 new architecture options, including some sparse IBM processors and Google's Sycamore. It also adds some helper functions and typing hints.

Changes

  • Adds optional qubit_map and reduce_order parameters to an Architecture, to separate the qubit identifiers from the internal vertex index representation.
    The reduce_order is used by the Steiner tree algorithms. It is computed automatically when not given.

  • Adds helper methods to find non-cutting nodes, and shortest paths.

  • Streamlines the steiner_tree implementation.

  • Adds some type annotations to the architecture module, and fixes mypy errors.

- Adds an optional qubit_map and reduce_order to an Architecture, to
  separate the qubit identifiers from the internal vertex index
  representation.
  The reduce_order is used by the steiner tree operations. It is
  computed automatically when not given.

- Adds helper methods to find non-cutting nodes, and shortest paths.

- Streamlines the steiner_tree implementation.

- Adds some type annotations to the architecture module, and fixes
  mypy errors.

Co-authored-by: Aerylia <[email protected]>
@jvdwetering
Copy link
Collaborator

Hi Augustin, thanks! And also congratulations with your thesis :)
Some mypy checks fail. Could you fix those before I merge?

@aborgna-q
Copy link
Contributor Author

Thanks John ! :)

The error should be fixed now.

@jvdwetering jvdwetering merged commit e0a3a81 into zxcalc:master Jan 21, 2023
@aborgna-q aborgna-q deleted the architecture_updates branch January 23, 2023 09:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants