Integrated Deployment of the Development and Operating Environments
Environment Requirements
- Servers with Atlas 300I inference card (model 3010)
- Servers with Atlas 300T training card (model 9000)
- Atlas 800 inference server (model 3010)
- Atlas 800 training server (model 9010)
Procedure
In the following procedure, {version} indicates the version number of the software package or compressed package, {arch} indicates the OS architecture, and {path} indicates the directory, in which the decompressed RUN package is to be saved. Replace them as required.
- Install msInstaller.
- Obtain the software package from Software Package Obtaining and upload it to any directory on the server, for example, /home/HwHiAiUser.
- Go to the directory where the software package is stored and run the following commands to grant permissions to the software RUN package and decompress the package:
chmod +x Ascend-xxx-toolbox_{version}_linux-{arch}.run ./Ascend-xxx-toolbox_{version}_linux-{arch}.run --extract={path}
- Run the cd {path}/MsInstaller command to go to the directory where the msInstaller package is stored, and run the following command:
tar xzvf msInstaller-{version}.tar.gz
- Start msInstaller.
- Non-root user:
./msInstaller-{version}.AppImage
- root user:
./msInstaller-{version}.AppImage --no-sandbox
- The ./msInstaller-{version}.AppImage command is used to start msInstaller. Pay attention to the following points:
- If a port conflict occurs when you run the preceding command, you can specify a port to solve the problem. The following is examples of the command:Non-root user:
./msInstaller-{version}.AppImage --port=5001
root user:
./msInstaller-{version}.AppImage --no-sandbox --port=5001
If you do not specify a port when running the command to start the msInstaller, port 5000 is used by default. If you need to specify a port, you are advised to use a port number ranging from 5001 to 65535. You can run the lsof -i:{port} command to check whether the port is occupied. In the command, {port} indicates the port number to be queried. Replace it with the actual port number.
- If a port conflict occurs when you run the preceding command, you can specify a port to solve the problem. The following is examples of the command:
- After the tool startup command is run, the msInstallerService backend program provides backend services. The parameters used by the backend program are as follows:
--help is used to view the help information.
-p --port is used to specify a bond port.
- Non-root user:
- After the command is executed, msInstaller is started and the welcome page is displayed. See Figure 5-1. After the welcome page is displayed, msInstaller is used to download the configuration file (containing the download address and detailed information about the software package) for installing and upgrading the software package.
- Click Install, select Atlas License, and click Next. The Set Development Environment page is displayed, as shown in Figure 5-2. The following figure shows the configuration page of the tool started by a non-root user. If the tool is started by the root user, Current User Password: is not displayed.
- Select MindStudio and Device Host (select Local).
- Make SD Card: used to create the system boot disk for the Atlas 200 DK developer kit (model 3000).
- For details about the installation scenarios, see Development Environment Overview.
- Set installation parameters according to Table 5-1 and click Check.Table 5-1 Parameter description
Parameter
Description
MindStudio
Install MindStudio and the Development Kit (toolkit).
- OS: OS and version.
- Architecture: OS architecture.
- kernel: OS kernel.
- MindStudio: MindStudio version.
- Current User Password: password of the current user, which is invisible when the root user uses the tool.
Device Host
Install the NPU driver and firmware, as well as inference or training software on Ascend devices.
- Local: scenario where the development and operating environments are deployed together. The NPU driver, firmware, and TensorFlow framework plugin package (tfplugin, only for training devices) need to be installed.
- OS: OS and version.
- Model: Atlas product model or processor model.
- Current User Password: password of the current user, which is invisible when the root user uses the tool.
- Remote: scenario where the development and operating environments are deployed separately.On the remote Ascend devices, install the NPU driver, firmware, toolbox, offline inference engine package (nnrt, for inference only), training software package (nnae, for training only), and TensorFlow framework plug-in package (tfplugin, for training only).
- IP: IP address of the remote Ascend device.
- Password: password of the root user.
After setting the parameters, click Connect to connect to the remote device.
- Click Next. The Install Options page is displayed.Configure the following parameters:
- Download Folder
Directory for uploading the downloaded software packages and signature files.
- Device Folder
Configure this parameter only when Device Host is set to Remote. This parameter indicates the upload directory of the remote Ascend device software package.
- Download Folder
- Click Next. The Download and Installing page is displayed, including MindStudio and Device Host tabs.
- Click the MindStudio tab and select the path where the software package is stored on the server.Click
. A dialog box as shown in Figure 5-3 is displayed. Click
. Select the following items in sequence and click OK to return to the Download and Installing page. Click Start to start the installation.
- Select MindStudio package: Select the path where the MindStudio software package is stored.
- Select toolkit x86 package: Select the path where the x86 toolkit software package is stored.
- Select toolkit arm package: Select the path where the ARM toolkit software package is stored.
- Click the Device Host tab, select the version of the uploaded software package from the drop-down list box, and click Start.
{version} indicates the version number of the software package in the directory specified by Download Folder on the Install Options page. The default directory is ~/msinstaller_download.
The Select version drop-down list box displays the version number of the uploaded software package. See Figure 5-4. Take the version 1.0 as an example. If you need to install the software of version 1.0, upload the software package of version 1.0 and the corresponding signature file to the Download Folder directory. After the security check is passed, the version number 1.0 is displayed in the Select version drop-down list box on the Download and Installing page for download and installation.
Click
to refresh the installation status. After the installation is complete, click Next. Completing Setup is displayed.
If the dialog box displayed during the installation is not an installation error, perform operations as prompted.
- Click the MindStudio tab and select the path where the software package is stored on the server.
- Click Finish to close msInstaller.
- The following describes how to configure MindStudio.Go to the MindStudio-ubuntu/bin directory generated after the software package is decompressed and run the following command as the installation user (the following startup commands cannot be executed in the background):
cd MindStudio-ubuntu/bin ./MindStudio.sh
- Open the import settings dialog box, as shown in Figure 5-5.
- Config or installation folder: imports MindStudio settings from an existing directory.
The directory is $HOME/.config/Huawei/MindStudioMS-x.x. The MindStudio settings include the personalized settings of the project UI such as the background color.
- Do not import settings (default): creates a configuration file.
Select an option and click OK.
- If you are installing MindStudio for the first time and have decompressed the MindStudio tar.gz package to the $HOME directory, the Previous version parameter is displayed in the dialog box shown in Figure 5-5.
- If an earlier version of MindStudio has been installed, the Previous version parameter is displayed in the dialog box shown in Figure 5-5 when you are installing a later version. You can choose whether to import the settings from the earlier version as required.
- If this version of MindStudio has been installed before, and the $HOME/.cache/Huawei/MindStudioMS-x.x and $HOME/.config/Huawei/MindStudioMS-x.x directories have not been deleted during the uninstallation, you will go to 8 directly from 12 when installing this version again. (x.x indicates the version number.)
- Config or installation folder: imports MindStudio settings from an existing directory.
- If Toolkit has been installed on the MindStudio installation server, go to 11. Otherwise, the dialog box shown in Figure 5-6 is displayed.
Click
next to Ascend Toolkit Path. On the dialog box that is displayed, select the Toolkit installation path (the version path must be selected). Click OK. The Toolkit version information is displayed in Ascend Toolkit Version and cannot be modified. Click OK.
- The dialog box shown in Figure 5-7 is displayed.
This dialog box is also displayed when you use MindStudio. You can determine whether to click Accept based on the site requirements. If you choose File > Settings... > Tools > Server Certificates on the menu bar and select Accept non-trusted certificates automatically, the certificates will be automatically accepted and this dialog box will not be displayed when you use MindStudio.
- Click Accept to allow MindStudio to connect to the upgrade server.
- Click Reject to reject MindStudio to connect to the upgrade server. This dialog box is displayed when you restart MindStudio next time.
- After clicking Accept or Reject, if no error message is displayed and the welcome page is displayed, MindStudio is successfully installed.
After the installation is successful, the following directories are created in $HOME on the MindStudio installation server:
- .mindstudio: includes the ADK installation path (the default Install Location path is used), MindStudio attribute file, and operations performed by the user on the privacy statement page.
- .cache/JetBrains/MindStudioMS-x.x: stores runtime logs (log/idea.log) generated after MindStudio installation and startup.
- .config/Huawei/MindStudioMS-x.x: stores user configuration, including personalized settings (such as the background color) of the project UI.
The following describes the parameters in the dialog box. You can click Creating an Application Project" or "Project Creation" in the MindStudio User Guide.
to create a project. For details, see "- Create new project: creates a project and save it in $HOME/AscendProjects.
- Open or Import: opens or imports a project.