Template Class TNCudaBase¶
Defined in File TNCudaBase.hpp
Inheritance Relationships¶
Derived Types¶
public Pennylane::LightningTensor::TNCuda::TNCuda< Precision, ExactTNCuda< Precision > >
(Template Class TNCuda)public Pennylane::LightningTensor::TNCuda::TNCuda< Precision, MPSTNCuda< Precision > >
(Template Class TNCuda)public Pennylane::LightningTensor::TNCuda::TNCuda< PrecisionT, Derived >
(Template Class TNCuda)
Class Documentation¶
-
template<class PrecisionT, class Derived>
class TNCudaBase¶ CRTP-enabled base class for cutensornet.
- Template Parameters
PrecisionT – Floating point precision.
Derived – Derived class to instantiate using CRTP.
Subclassed by Pennylane::LightningTensor::TNCuda::TNCuda< Precision, ExactTNCuda< Precision > >, Pennylane::LightningTensor::TNCuda::TNCuda< Precision, MPSTNCuda< Precision > >, Pennylane::LightningTensor::TNCuda::TNCuda< PrecisionT, Derived >
Public Functions
-
TNCudaBase() = delete¶
-
inline explicit TNCudaBase(const std::size_t numQubits, int device_id = 0, cudaStream_t stream_id = 0)¶
-
inline ~TNCudaBase()¶
-
inline auto getQubitDims() const -> const std::vector<std::size_t>&¶
Get dimension of each qubit.
- Returns
const std::vector<std::size_t> &
-
inline auto getQubitDims() -> std::vector<std::size_t>&¶
Get dimension of each qubit.
- Returns
std::vector<std::size_t> &
-
inline auto getNumQubits() const -> std::size_t¶
Get the number of qubits of the simulated system.
- Returns
std::size_t
-
inline auto getCudaDataType() const -> cudaDataType_t¶
Get the CUDA data type.
- Returns
cudaDataType_t
-
inline auto getTNCudaHandle() const -> cutensornetHandle_t¶
Get the cutensornet handle that the object is using.
- Returns
cutensornetHandle_t
-
inline auto getQuantumState() const -> cutensornetState_t¶
Get the quantum state pointer.
- Returns
cutensornetState_t
-
inline auto getDevTag() const -> const DevTag<int>&¶
Get device and Cuda stream information (device ID and the associated Cuda stream ID).
- Returns
DevTag