MindStudio Configuration

  1. Go to the bin folder in the MindStudio installation directory, and double-click the MindStudio application to start MindStudio.
  2. After MindStudio is installed, the user license agreement page is displayed when you start MindStudio for the first time, as shown in Figure 1.
    Figure 1 User license agreement
    • Select the check box at the bottom to accept the agreement, and then click Continue to go to 3.
    • Click Exit to close MindStudio.
  3. Open the settings import dialog box, as shown in Figure 2.
    Figure 2 Environment settings
    • Config or installation directory: imports MindStudio settings from a custom configuration directory.

      The directory is in the C:\Users\username\AppData\Roaming\MindStudioMS-{version} path. The MindStudio settings include personalized settings of the project UI such as the background color.

    • Do not import settings (default): creates a configuration file without importing settings.

    Select an option as required and click OK.

    • If an earlier MindStudio installation is detected, the Previous version parameter is displayed in the dialog box shown in Figure 2 when you are installing a later version. You can choose whether to import the settings from the earlier version as required.
    • If MindStudio of the same version is detected and the C:\Users\username\AppData\Roaming\Huawei\MindStudioMS-{version} and C:\Users\username\.mindstudio directories are not deleted when you uninstall the previous version, the re-installation proceeds to 4 from 3.
  1. If no error is reported and the welcome page is displayed, MindStudio is successfully installed. See Figure 3.
    Figure 3 Welcome page
    Table 1 Parameters

    Parameter

    Description

    Projects tab page (project management)

    New Project

    Create a project.

    Open

    Open an existing project.

    Get from VCS

    Use the version control tool to download the code repository and open it.

    Customize tab page (settings customization)

    Color theme

    Set the color theme.

    Accessibility

    Set auxiliary functions, including setting the IDE font size and adjusting the colors for users with red and green visual defects.

    Keymap

    Set keyboard mapping. MindStudio automatically recommends a predefined keyboard mapping based on your environment. Ensure that it matches the OS you are using. Alternatively, you can manually select an OS that matches the shortcuts in another IDE or editor that you are accustomed to.

    Import Settings...

    Import personalized MindStudio settings from the customized configuration directory.

    All Settings...

    Switch to the Settings page.

    Plugins tab page (plugin management)

    Marketplace

    Search for and download required plugins from the plugin market.

    Installed

    Check the installed plugins.

    Learn tab page (MindStudio help)

    After the installation is successful, the following directories are created on the local Windows host:

    • C:\Users\username\.mindstudio: stores the MindStudio property file and records of operations performed by users in the privacy statement window.
    • C:\Users\username\AppData\Local\Huawei\MindStudioMS-{version}: stores run logs generated during MindStudio installation and after startup.
    • C:\Users\username\AppData\Roaming\Huawei\MindStudioMS-{version}: stores user configuration data, including the Toolkit installation path (mindstudio.properties file), and personalized settings (such as the background color) of the project UI.

    The AppData directory is hidden by default. You can click View above the folder and select Hidden items from the drop-down list to display the AppData directory.

  2. Create a project or open an existing project.
    • On the Projects tab page, click New Project to create a project. If the new project is an Ascend operator project, as shown in Figure 4, you need to configure the Ascend-CANN-Toolkit installation path. Click Change, go to step 6, and perform subsequent operations as prompted.
      Figure 4 Creating an Ascend operator project (example)
    • On the Projects tab page, click Open to open an existing Ascend project. A dialog box shown in Figure 5 is displayed, indicating that the functions provided by MindStudio may execute potential malicious code in the project. In this case, confirm the code before opening the project.
      Figure 5 Trust configuration window
      • Trust projects in {directory where the project is located}: Trust all projects in the directory where this project is located.
      • Trust Project: Trust this project.
      • Preview in Safe Mode: Preview the project in safe mode.
      • Don't Open: Do not open the project.
      If the opened project is an Ascend project (using an application project as an example), a dialog box shown in Figure 6 is displayed. Click OK.
      Figure 6 CANN package not installed

      The window shown in Figure 7 is displayed. Click the Change button and go to 6.

      Figure 7 Modifying the properties of the application project (example)

    For details about the parameters for creating a project from New Project or opening an existing project from Open, see "Project Management > Project Creation > Ascend Projects/Non-Ascend Projects" in the MindStudio User Guide.

    On the Projects tab page, click Get from VCS. On the version management page displayed, configure the URL of the Git repository and click Clone to download and open the project (stored in C:\Users\username\MindstudioProjects by default).

    The process of opening an Ascend project downloaded from the version management page is the same as the process of opening an existing Ascend project by clicking Open on the Projects tab page.

  3. On the page shown in Figure 8, click to connect the Windows environment where MindStudio is located to the remote development environment where Ascend-CANN-Toolkit is located. Click next to Remote CANN location. In the dialog box displayed, select the installation path of the Ascend-CANN-Toolkit (including the version number).
    Figure 8 Connecting to the remote CANN
  4. On the SSH connection configuration page, click to configure the SSH connection parameters. Click OK, as shown in Figure 9.
    Figure 9 SSH configuration
    Table 2 Parameters and icons

    Parameter/Icon

    Description

    Lock the current connection

    The option is dimmed and cannot be operated. If an SSH connection is added to the cluster management, this option is automatically selected. In this case, the SSH connection is locked and cannot be modified and deleted.

    Host

    Destination address of the connection (IP address or domain name)

    The IP address can be an IPv4 or IPv6 address.

    NOTE:

    An IPv6 address starting with fe80 is not supported, as it is a link-local address that can only be used within a subnet. To log in to a device using this address, you need to enter the corresponding network port name, which is not in line with the input format on the SSH connection page in MindStudio.

    Port

    Port number of the destination address of the connection. The default value is 22.

    User name

    Username for logging in to the destination address.

    Authentication type

    Authentication method. Two methods are available:

    • Password: Enter a password for authentication.
    • Key pair: Use an SSH key for authentication. For details about how to request an SSH key, see "Basic Operations > SSH Connection Management" in the MindStudio User Guide.

    Password

    Available when Authentication type is set to Password. Enter the correct password. You can select Save password to save the password.

    NOTE:

    If Save password is not selected, the password will be automatically cleared 24 hours later. When the SSH is used again, you need to enter the password again before executing the SSH task.

    Private key file

    Available when Authentication type is set to Key pair. Select a local private key file.

    Passphrase

    Available when Authentication type is set to Key pair. Enter the correct passphrase. You can select Save password to save the passphrase.

    Test Connection

    Checks whether the connection is successful.

    Adds a new SSH connection.

    Deletes an SSH connection. Select an SSH connection to be deleted and click this icon.

  5. Enter the Ascend-CANN-Toolkit installation path in the remote environment. See Figure 10.
    Figure 10 Ascend-CANN-Toolkit installation path
  6. Enter MindStudio and choose File > Settings > Plugins to search for the following plugin tools in the plugin market and install them:
    • Grep Console
    • Pylint