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

Add ECR gate #234

Merged
merged 9 commits into from
Jun 7, 2024
Merged

Add ECR gate #234

merged 9 commits into from
Jun 7, 2024

Conversation

vincentgierisch
Copy link
Contributor

Add echoed-resonance (ECR) gate

Copy link
Member

@edyounis edyounis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome! Thanks for taking this upon yourself to add. This is very much a welcome addition, thanks also for getting the unitary endian ordering correct.

Besides the two minor points below, can you add a test that ensures we can read and write this gate properly to qasm. You may need to a GateDef in the qasm visitor module.

bqskit/ir/gates/constant/__init__.py Show resolved Hide resolved
bqskit/ir/gates/constant/ecr.py Show resolved Hide resolved
@edyounis
Copy link
Member

Awesome! Just one more test to get this approved and merged in. Can you do a encode-decode-in-one test? As in create a circuit with an ECRGate, save to qasm with Circuit.to, then load that qasm in. I do expect that the resulting circuit will be composed of a CircuitGate with the decomposed gates, but it is good to check there are no crashes and that the input and output unitaries are the same.

@vincentgierisch vincentgierisch marked this pull request as draft May 4, 2024 15:42
@vincentgierisch vincentgierisch marked this pull request as ready for review May 18, 2024 01:59
@vincentgierisch vincentgierisch requested a review from edyounis May 18, 2024 13:12
@edyounis edyounis merged commit f38c36c into BQSKit:main Jun 7, 2024
17 checks passed
@nquetschlich nquetschlich mentioned this pull request Jun 18, 2024
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