Quantum Computing Language Converter
npm -g install q-convert
Q-Convert - Quantum Language Converter
Usage:
q-convert -i input_file -s source_format -o output_file -d destination_format [-j] [-w]
-i, --input Input file
-s, --source Source format: qasm, quil, qobj, ionq, quantum-circuit, toaster
-o, --output Output file
-d, --dest Destination format: qiskit, qasm, qasm-ext, qobj, quil, pyquil, braket, cirq, tfq, qsharp, quest, js, quantum-circuit, toaster, svg, svg-inline
-j, --jupyter Output jupyter notebook (for qiskit, pyquil, braket, cirq, tfq, qsharp, and js only)
-w, --overwrite Overwrite output file if it already exists
-h, --help Print this help text
The following command will take my_circuit.qasm
and output vector image of circuit diagram my_circuit.svg
q-convert -i my_circuit.qasm -s qasm -o my_circuit.svg -d svg -w
Convert from QASM to Q# (QSharp)
q-convert -i my_circuit.qasm -s qasm -o my_circuit.qs -d qsharp -w
Convert from QASM to jupyter notebook with pyQuil code inside:
q-convert -i my_circuit.qasm -s qasm -o my_circuit.ipynb -d pyquil -j -w
Online version is available at: https://quantum-circuit.com/qconvert
More input & output languages will be added soon.
That's it. Enjoy!