uniqc.visualization.circuit module¶
Quantum circuit visualization tools.
Deprecated since version The: module-level draw / draw_html wrappers are deprecated in favor
of uniqc.visualization.render() (or equivalently
Circuit.draw(...)), which offer self-developed text art (no pyqpanda3
dependency), SVG/PNG/LaTeX/HTML/interactive modes, styles, folding, and
full OriginIR-ext coverage. The wrappers will be removed in uniqc 0.2.0.
- uniqc.visualization.circuit.draw(ir_str, language='OriginIR')[source]¶
Draw the circuit in text format. Deprecated — use
render(mode="text").- Parameters:
ir_str (str) – The input circuit in OriginIR or QASM format.
language (str) – Deprecated. The language is now auto-detected from the content (
QINIT/OPENQASMheaders).
- Returns:
The rendered ASCII drawing (also printed for backwards compatibility).
- Return type:
- uniqc.visualization.circuit.draw_html(ir_str, language='OriginIR', output_path=None, *, title='Quantum circuit')[source]¶
Render a static HTML/SVG circuit diagram. Deprecated — use
render(mode="html").- Parameters:
ir_str (str) – The input circuit in OriginIR or QASM format.
language (str) – Deprecated. Auto-detected from content.
output_path – Optional path to write the HTML document to.
title – Ignored (kept for signature compatibility).
- Returns:
The self-contained HTML document.
- Return type:
str