cuquantum.cutensornet.expectation_get_info¶
- cuquantum.cutensornet.expectation_get_info(intptr_t handle, intptr_t tensor_network_expectation, int attribute, intptr_t attribute_value, size_t attribute_size)[源代码]¶
检索与请求的张量网络状态期望值的计算相关的属性。
- 参数
handle (intptr_t) – cuTensorNet 库句柄。
tensor_network_expectation (intptr_t) – 张量网络状态期望值表示。
attribute (ExpectationAttribute) – 信息属性。
attribute_value (intptr_t) – 指向信息属性值的指针(类型擦除)。
attribute_size (size_t) – 信息属性值的大小。
注意
要计算属性大小,请使用相应数据类型的 itemsize,可以使用
get_expectation_attribute_dtype()
查询。