3
$\begingroup$

I have a quantum circuit in qiskit. Now I want to know is there any way that I can transform it to a braket circuit in AWS? I want to use error mitigation in AWS. I have the circuit in qiskit. But as error mitigation in AWS only accept braket circuit I have to somehow transform the qiskit circuit to braket circuit. How I can solve this problem?

$\endgroup$
3
  • $\begingroup$ I don't know anything about braket, sorry if it's not useful, but if it supports openQASM then you can transform the qiskit circuit into openQASM string and back to braket maybe? $\endgroup$
    – Lena
    Commented Jan 16, 2023 at 10:42
  • $\begingroup$ Ok. I will try to do that. $\endgroup$ Commented Jan 16, 2023 at 11:27
  • $\begingroup$ There is a similar question with newer answers. How to Properly Run a Circuit with Qiskit on AWS Braket $\endgroup$ Commented Mar 26 at 8:59

2 Answers 2

3
$\begingroup$

I'm not sure if this actually solves your problem but Amazon Braket recently released a Qiskit provider that you can install by pip install qiskit-braket-provider. This tool let you to run your Qiskit QuantumCircuit by using Braket Python SDK:

from qiskit import QuantumCircuit
from qiskit_braket_provider import BraketLocalBackend

circ = QuantumCircuit()
# build your Qiskit circuit here
# ...

local_simulator = BraketLocalBackend()
task = local_simulator.run(circ, shots=1000)

Take a look at this link for more details: Introducing the Qiskit provider for Amazon Braket.

$\endgroup$
1
  • $\begingroup$ Ok. Thanks! let me see $\endgroup$ Commented Jan 17, 2023 at 12:05
3
$\begingroup$

You can transpile circuits from qiskit to braket using the qBraid SDK. For example:

from qbraid import circuit_wrapper
from qiskit import QuantumCircuit

qiskit_circuit = QuantumCircuit()
# ...

braket_circuit = circuit_wrapper(qiskit_circuit).transpile("braket")
 

See:

Note: Right now the qBraid SDK is only available on lab.qbraid.com, but will be open-sourced very soon!

$\endgroup$
2
  • $\begingroup$ oky.. let me check $\endgroup$ Commented Jan 17, 2023 at 12:05
  • $\begingroup$ Sounds good, let me know if you need any additional guidance with setup! $\endgroup$
    – ryanhill1
    Commented Jan 17, 2023 at 15:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.