QPanda3  0.1.0
Supported by OriginQ
Loading...
Searching...
No Matches
Quantum Profiling

Prev Tutorial: Hamiltonian
Next Tutorial: Quantum Cloud Service


Profiling Module Tutorial

This tutorial provides an overview of the profiling capabilities available for quantum circuits using the functions draw_circuit_features and draw_circuit_profile. These functions allow users to visualize circuit features and performance metrics effectively.

Overview

Quantum circuits are complex structures that often require detailed analysis to understand their performance characteristics. The Profiling module offers tools to visualize these aspects through radar charts for circuit features and performance profiles for execution times.

draw_circuit_features

draw_circuit_features visualizes the features of a quantum circuit by generating a radar chart. It computes several metrics related to the circuit's structure and behavior, including connectivity, liveness, parallelism, entanglement, and critical depth.

draw_circuit_profile

draw_circuit_profile generates a performance profile of a quantum circuit, illustrating the execution times of individual quantum gates. It helps in identifying bottlenecks and optimizing performance.

Example Usage

After running, two images will be generated as shown below:

Quantum Circuit Features
Quantum Circuit Profile
Note
  • To use draw_circuit_profile, you need to install the Graphviz library first.