No relevant resource is found in the selected language.
This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>
Your browser version is too early. Some functions of the website may be unavailable. To obtain better user experience, upgrade the browser to the latest version.
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document.
Note: Even the most advanced machine translation cannot match the quality of professional translators.
Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
Function: numpy_to_ptr
Function: numpy_to_ptr
C Prototype
None
Python Function
ptr = acl.util.numpy_to_ptr(data)
Function Usage
Converts NumPy data into void* data. The converted data can be transferred to the C function for direct use.
Input Description
data: data of the NumPy type.
Return Value
ptr: int, data that can be accessed by the C language.
Restrictions
For example, if data of the int type is accessed, void* needs to be converted into int*.