-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Left justify the circuit in text visualizer #1707
Comments
In a circuit such as
The fully left justified circuit would be
However this now no longer respects the order in which the gates were declared, and I think would be less helpful to users. I think it would be better to follow the style already used in the matplotlib drawer and produce a circuit where the gates are in their own columns, in the order they were declared. This will take up more space but would be clearer. |
In practice on a device, gates are right justified (ie. gates are done as late as possible). The above could be confusing to users (I don't have a better solution, just wanted to note this). |
When I output that circuit to matplotlib the image I get is |
Sure, I think there is merit to a right justified drawing as well. Left-justified is common in backend-agnostic circuits (textbooks, papers). Also the device schedule is something that is backend-specific and can change with different schedulers. I think if we could have this as a drawing option in |
What is the expected enhancement?
Currently when a circuit is displayed using the text drawer each gate in a circuit sits in its own column, as shown in the following circuit.
It would be better if the circuits could be left justified, so the above circuit would appear as below.
It appears that circuits are already justified like this in the matplotlib drawer.
The text was updated successfully, but these errors were encountered: