Function: set_tensor_place_ment
Applicability
Product |
Supported (√/x) |
|---|---|
√ |
|
√ |
|
√ |
|
√ |
|
√ |
Function Usage
Sets the placement attribute of a tensor description to identify whether the tensor memory is host memory or device memory.
Prototype
- C Prototype
1aclError aclSetTensorPlaceMent(aclTensorDesc *desc, aclMemType memType)
- Python Function
1ret = acl.set_tensor_place_ment(desc, mem_type)
Parameter Description
Parameter |
Description |
|---|---|
desc |
Int, pointer address of the tensor description. Call acl.create_tensor_desc in advance to create the tensor description of an operator input or output as the input of this API. |
mem_type |
Int, placement attribute value. For details about the value, see aclMemType. |
Return Value Description
Return Value |
Description |
|---|---|
ret |
Int, error code.
|
Parent topic: aclmdlTensorDesc