qml.transforms.core.transform_dispatcher

This module contains the transform dispatcher and the transform container.

Classes

TransformContainer(transform[, args, ...])

Class to store a quantum transform with its args, kwargs and classical co-transforms.

TransformDispatcher(*args, **kwargs)

Converts a transform that has the signature (tape -> Sequence(tape), fn) to a transform dispatcher that can act on pennylane.tape.QuantumTape, quantum function, pennylane.QNode, pennylane.devices.Device.

Functions

register_primitive_for_expansion(primitive, ...)

Register a transform such that it can be expanded when applied to a function with program capture enabled.

Exceptions

TransformError

Raised when there is an error with the transform logic.