Skip to content
This repository has been archived by the owner on Jan 12, 2024. It is now read-only.

Visualizing small circuits with %trace often creates deeply nested trace that requires a lot of clicks #595

Open
guenp opened this issue Feb 22, 2022 · 2 comments
Labels
Area-Kernel Issue relates to the IQ# kernel. Kind-Enhancement New feature or request

Comments

@guenp
Copy link
Contributor

guenp commented Feb 22, 2022

Is your feature request related to a problem? Please describe.
It can be a bit of a hassle to visualize small circuits and having to click manually to expand all operations.

Describe the solution you'd like
It would be great if small circuits are automatically expanded, or if there is an --expand flag we can use to automatically expand the entire circuit (equivalent to --depth but without providing an int value).

Describe alternatives you've considered

Additional context
Screenshot:
Screen Shot 2022-02-22 at 9 55 19 AM

@cgranade
Copy link
Contributor

Thanks for filing this, makes sense! We should also likely expose default values for --depth and --expand through to %config so that they can be set notebook-wide or even folder-wide (using %config --save).

@cgranade cgranade added Area-Kernel Issue relates to the IQ# kernel. Kind-Enhancement New feature or request labels Feb 22, 2022
@cgranade
Copy link
Contributor

Investigating a little further, this may require a modification to quantum-viz.js as well, since that library's public API doesn't currently expose expansion and collapsing of subcircuits (https://github.com/microsoft/quantum-viz.js/blob/c618233037b1d3150900e7dee526c7c08f4ae95f/src/sqore.ts#L70). +@anpaz for quantum-viz.js discussion.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Area-Kernel Issue relates to the IQ# kernel. Kind-Enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants