Installing KRL
This section describes how to install KRL using the RPM package and verify the package. Using parameters supported by the RPM package manager but not documented in this guide may result in undefined behavior. Proceed with caution.
- Obtain the KRL software installation package BoostKit-boostsra-krl_1.0.0.zip from the GitCode repository. Unzip the ZIP file to obtain the RPM installation package.
- Before using the software package, read and agree to Kunpeng BoostKit User License Agreement 2.0.
- The KRL software package consists of the following files:
1 2 3 4
├── boostsra-krl-1.0.0-1.aarch64.rpm ├── 0001-faiss-1.8.0-add-krl.patch ├── Kunpeng BoostKit User License Agreement 2.0 (in Chinese).txt └── Kunpeng BoostKit User License Agreement 2.0.txt
boostsra-krl-xxxx.aarch64.rpm contains the KRL header files and dynamic library files. 0001-faiss-1.8.0-add-krl.patch is the patch file required for enabling KRL in Faiss 1.8.0. xxxx indicates the KRL software package version.
- Install the RPM package.
1rpm -ivh boostsra-krl-xxxx.aarch64.rpm
After the installation is complete, the environment variable LD_LIBRARY_PATH is automatically added to /etc/profile, that is, the /usr/local/sra_krl/lib directory where the KRL dynamic library files are stored.
In the preceding command, xxxx indicates the version.
- Run the source command or re-log in to the terminal to apply the environment variable.
1source /etc/profile
- Check whether the environment variable LD_LIBRARY_PATH contains the KRL installation path /usr/local/sra_krl/lib.
1env | grep LD_LIBRARY_PATH
If the variable contains the installation path, the installation is successful.
After the installation, the target files are generated in the installation path (the default path is /usr/local/sra_krl), where the include folder contains the KRL header files, and the lib folder contains the KRL dynamic library files.