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

Chaseklvk/add amplitude estimation braket #44

Closed
wants to merge 4 commits into from

Conversation

chaseklvk
Copy link
Collaborator

@chaseklvk chaseklvk commented Jan 27, 2022

This PR adds an Amazon Braket implementation of the Amplitude Estimation benchmark.

Here are a couple notes about this implementation:

  1. I found that Braket just doesn't support certain features natively, namely, adjoint circuits, multi-cnot gates, etc. (at least not obviously from the documentation), so I had to implement many of those functions by hand. It sounds like it might be useful to compile a general set of Braket utils useful across all benchmarks.

  2. The main implementation is located in braket/ae_benchmark.py and the utilities mentioned in point 1 are located in braket/ae_utils.py.

  3. I tried to keep the benchmark itself as uniform as possible with respect to the existing benchmarks with some small differences due to Braket's limitations.

  • When generating Q, instead of returning cQ and Q, the function Q_Unitary returns the Q circuit object as well as the unitary matrix of Q which is later supplied to controlled_unitary() when creating the general circuit.
  • I kept a vanilla python list of qubit numbers to use similar to QuantumRegister in Qiskit

Let me know if you have any questions! I'm not sure if there's any established workflow, so I just assumed based on the branches that I should PR into develop. Please let me know if there's a different established flow.

@chaseklvk
Copy link
Collaborator Author

chaseklvk commented Feb 1, 2022

@rtvuser1 I updated this pull request to use MCX implementation in Grover's. Once I made this change, simulated fidelities deteriorated. The only part that changed is the MCX gate. It would be great if someone else can also validate this code and the circuits its generating.

@rtvuser1 rtvuser1 deleted the branch develop January 11, 2024 07:41
@rtvuser1 rtvuser1 closed this Jan 11, 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.

None yet

2 participants