Open tanujkhattar opened 2 years ago
potentially helpful aside: jupyter notebook has documentation and templates for writing interactive Widget
s that can make interactable things using mainly-python (instead of e.g. writing a complete javascript visualizer).
I also think we should move away from the "fixed musical score" layout and lean into a tensor-network type graph visualization
follow up: #246
Most of the circuits we build using this library will be large nested circuits, where we have a few composite outer level operations like loading data from QROM, selectively applying a linear combination of unitaries via
Select
etc. When visualizing these circuits, it would be useful to provide an interactive visualization tool to users so they can click on a "composite" operation and zoom into it's implementation (which can be obtained by callingcirq.decompose_once(op)
on the composite operation). and then zoom out back to top level if needed.One example of such a visualization is: https://github.com/microsoft/Quantum/tree/main/samples/algorithms/integer-factorization#quantum-vizjs-visualization. We should build a similar version for Cirq that's scalable and doesn't add new unnecessary qubits.