Sample Reference
Sample Obtaining and Using
Precautions for Using the Build Script
The sample provides a build script, which requires only few manual tweaks to the following variables.
- ASCEND_PATH: /ascend-toolkit/latest/ in the Ascend-CANN-Toolkit installation path.
- INCLUDES: header files to be included. Append new header files (if any) to the existing lines. Do not delete the existing lines. If the network contains a custom operator, include the header file of its prototype definition.
- LIBS: libraries to be linked. Append new libraries (if any) to the existing lines. Do not delete the original lines.
Do not link with other .so files in the runfile, as this may cause compatibility problems during version upgrade.
Environment Variables for Running an Application
After the CANN software is installed, when you build and run your application as the CANN running user, log in to the environment as the CANN running user and run the source ${install_path}/set_env.sh command to set environment variables. {install_path} indicates the CANN installation path, for example, /usr/local/Ascend/ascend-toolkit.
