pygsti.forwardsims.torchfwdsim

pygsti.forwardsims.torchfwdsim#

Defines a ForwardSimulator class called “TorchForwardSimulator” that can leverage the automatic differentation features of PyTorch.

This file also defines two helper classes: StatelessCircuit and StatelessModel.

See also: pyGSTi/modelmembers/torchable.py.

Classes

StatelessCircuit(spc)

Helper data structure for specifying a quantum circuit (consisting of prep, applying a sequence of gates, and applying a POVM to the output of the last gate).

StatelessModel(model, layout)

A container for the information in an ExplicitOpModel that's "stateless" in the sense of object-oriented programming:

TorchForwardSimulator([model])

A forward simulator that leverages automatic differentiation in PyTorch.