You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We would like to add a QasmModule.draw() method that generates a circuit diagram from a parsed OpenQASM program (i.e. an openqasm3.ast.Program object). This method can either generate either a raw ASCII string or leverage external visualization tools like pylatex, but should depend on any other quantum packages outside of the openqasm3.
Because of the large number of gates and operations supported by OpenQASM, we will restrict this first implementation to a smaller gate-set to make it a little more approachable. For this, you can use the following code to generate random qasm strings to use as the test data/files for the circuit drawer. Once the circuit drawer is reliably working for any circuits generated by this function, then we will consider this issue closed, and open a new issue that expands the scope.
We would like to add a
QasmModule.draw()
method that generates a circuit diagram from a parsed OpenQASM program (i.e. anopenqasm3.ast.Program
object). This method can either generate either a raw ASCII string or leverage external visualization tools like pylatex, but should depend on any other quantum packages outside of theopenqasm3
.Because of the large number of gates and operations supported by OpenQASM, we will restrict this first implementation to a smaller gate-set to make it a little more approachable. For this, you can use the following code to generate random qasm strings to use as the test data/files for the circuit drawer. Once the circuit drawer is reliably working for any circuits generated by this function, then we will consider this issue closed, and open a new issue that expands the scope.
The text was updated successfully, but these errors were encountered: