qml.utils

Warning

Unless you are a PennyLane or plugin developer, you likely do not need to use these utility functions.

This module contains utilities and auxiliary functions which are shared across the PennyLane submodules.

Functions

expand(U, wires, num_wires) Expand a multi-qubit operator into a full system operator.
unflatten(flat, model) Wrapper for _unflatten().

Classes

OperationRecorder() A template and quantum function inspector, allowing easy introspection of operators that have been applied without requiring a QNode.
Recorder(old_context) Recorder class used by the OperationRecorder.