|
Maestro 0.2.11
Unified interface for quantum circuit simulation
|
Tensor Contractor interface. More...
#include <TensorContractor.h>
Public Types | |
| using | TensorsMap |
Public Member Functions | |
| virtual std::shared_ptr< ITensorContractor > | Clone () const =0 |
| Clone the tensor contractor. | |
| virtual double | Contract (const TensorNetwork &network, Types::qubit_t qubit)=0 |
| Contract the tensor network. | |
| virtual size_t | GetMaxTensorRank () const =0 |
| virtual bool | GetMultithreading () const =0 |
| Get the multithreading flag. | |
| virtual TensorsMap | InitializeTensors (const TensorNetwork &network, Types::qubit_t qubit, std::vector< Eigen::Index > &keys, std::unordered_map< Eigen::Index, Eigen::Index > &keysKeys, bool fillKeys=true, bool contract=true)=0 |
| virtual void | SetMultithreading (bool multithreading=true)=0 |
| Enable/disable multithreading. | |
Tensor Contractor interface.
Defines an interface for tensor contractions. There might be different implementations for different types of contractions.
Definition at line 34 of file TensorContractor.h.
Definition at line 36 of file TensorContractor.h.
|
pure virtual |
Clone the tensor contractor.
Implemented in TensorNetworks::DumbContractor, TensorNetworks::ForestContractor, TensorNetworks::LookaheadContractor, TensorNetworks::StochasticContractor, and TensorNetworks::VerticalContractor.
|
pure virtual |
Contract the tensor network.
| Distributed Quantum Computing | The tensor network to contract. |
Implemented in TensorNetworks::DumbContractor, TensorNetworks::ForestContractor, TensorNetworks::LookaheadContractor, TensorNetworks::StochasticContractor, and TensorNetworks::VerticalContractor.
|
pure virtual |
Implemented in TensorNetworks::BaseContractor.
|
pure virtual |
Get the multithreading flag.
Returns the multithreading flag.
Implemented in TensorNetworks::BaseContractor.
|
pure virtual |
Implemented in TensorNetworks::BaseContractor.
|
pure virtual |
Enable/disable multithreading.
Enable/disable multithreading. Default is enabled.
| multithreading | A flag to indicate if multithreading should be enabled. |
Implemented in TensorNetworks::BaseContractor.