create_state_projection_mps#
-
cuquantum.
bindings. cutensornet. create_state_projection_mps( - intptr_t handle,
- int32_t num_states,
- tensor_network_states,
- intptr_t coeffs,
- int32_t symmetric,
- int32_t num_envs,
- intptr_t spec_envs,
- int boundary_condition,
- int32_t num_tensors,
- qudits_per_tensor,
- extents_out,
- strides_out,
- dual_tensors_data_out,
- intptr_t ortho_spec,
Creates an accumulative matrix product state (MPS) projection of a set of tensor network states.
- Parameters:
handle (intptr_t) – cuTensorNet library handle.
num_states (int32_t) – Number of tensor network states for which the MPS projection is computed. Currently only a single tensor network state is supported.
tensor_network_states (object) –
Tensor network states. It can be:
coeffs (intptr_t) – CPU accessible pointer to scalar coefficients for each tensor network state. If the tensor network states are of real datatype, the complex component of the coefficients will be ignored. A nullptr for this argument will be interpreted as unit coefficient for all network states.
symmetric (int32_t) – Whether or not the initial state of all tensor network states is defined by the values of the dual MPS tensors (in case of a symmetric MPS functional).
num_envs (int32_t) – Number of requested environments.
spec_envs (intptr_t) – Specification of each requested environment. Environments are specified by providing the qudit indices to the left and right of the excluded MPS tensors. Note that currently only 1-site environments are supported.
boundary_condition (BoundaryCondition) – Boundary condition of the MPS. Currently only open boundary condition MPS are supported.
num_tensors (int32_t) – Number of tensors contained in the MPS. Currently, num_tensors must be equal to the number of qudits in the MPS.
qudits_per_tensor (object) –
Number of consecutive qudits in each MPS tensor. Currently, qudits_per_tensor must be equal to 1. A nullptr for this argument will be interpreted as a single qudit per tensor. It can be:
an
int
as the pointer address to the array, ora Python sequence of
int32_t
.
extents_out (object) –
Maximum mode extents of all dual MPS output tensors, passed as array of length number of qudits, holding pointer to integer arrays. For pure states all extent arrays are of length 3, with the exception of open boundary condition MPS for which the first and last extent arrays are of length 2. It can be:
strides_out (object) –
Strides of all dual MPS output tensors, passed as array of length number of qudits, holding pointer to integer arrays. For pure states all stride arrays are of length 3, with the exception of open boundary condition MPS for which the first and last stride array are of length 2. It can be:
dual_tensors_data_out (object) –
GPU-accessible pointers for storing dual MPS tensors. Note that the MPS tensors residing in these data buffers are not conjugated, and will be conjugated on-the-fly during the environment contraction.
state_projection_mps_extract_tensor()
andstate_projection_mps_insert_tensor()
have side effects on the provided data. It can be:ortho_spec (intptr_t) – Specification of the orthogonality conditions on the provided MPS tensors.
- Returns:
MPS projection of a set of tensor network states.
- Return type:
intptr_t