-
Notifications
You must be signed in to change notification settings - Fork 61
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
Matplotlib circuit drawer #1370
Matplotlib circuit drawer #1370
Conversation
…mtzlosa/qibo into matplotlib-circuit-drawer
for more information, see https://pre-commit.ci
…mtzlosa/qibo into matplotlib-circuit-drawer
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are things that may still be improved. But that will be the case forever ^^
As the first implementation of this feature in Qibo, it is definitely acceptable.
Thanks a lot @sergiomtzlosa! :)
Co-authored-by: Alessandro Candido <[email protected]>
Co-authored-by: Alessandro Candido <[email protected]>
for more information, see https://pre-commit.ci
Co-authored-by: Alessandro Candido <[email protected]>
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot @sergiomtzlosa for this!
A few comments follow.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot for the modifications @sergiomtzlosa.
If it is fine with you I would prefer to align the docstrings style with the rest of Qibo :) The docstrings here are a bit different from the "canonical" way we do them. You can take this or this as examples (I just selected them randomly).
Finally, I was wondering if we aim to add the mpldrawer
to the documentation. In that case we have to add it to the doc/source files. I think it would be nice to prepare a simple example to show the users how to use the drawer :)
Once this is done, I think we are ready to merge!
Hi, Thanks a lot for your support and advices, I have uploaded the documentation and gave and example on the doc/source path, please, let me know if this is enough of not. Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot @sergiomtzlosa!
A new class named MPLDrawer to draw the circuit using matplotlib, this is a code integration and enhancement from https://github.com/rpmuller/PlotQCircuit.
The circuit now has a function called draw_mpl() to invoke matplotlib on drawing.
Checklist: