Prerequisites

Environment Setup

  1. Prepare an inference server powered by Atlas inference productss and install the corresponding driver and firmware.
  2. Install the Ascend-CANN-Toolkit. For details, see "Installing the Development Environment" in the CANN Software Installation Guide.
  3. Install MindStudio. For details, see "Installing MindStudio (Linux)" in the MindStudio Installation Guide.
  4. Set the environment variable.
    1. Log in as the running user, run the vi ~/.bashrc command in any directory to open the .bashrc file, and append the following content to the file (the default installation path of a non-root user is used as an example):
      # Ascend-CANN-Toolkit environment variable. Change it to the actual path.
      source ~/Ascend/ascend-toolkit/set_env.sh
    2. Run the :wq! command to save the file and exit.
    3. Run the source ~/.bashrc command for the modification to take effect immediately.

Data Preparation

Obtain the third-party model file.

Download the ResNet-50 network model file (.prototxt) and weight file (.caffemodel) from the following links and upload them to the project_directory/model directory on the MindStudio installation server as the MindStudio installation user. If the directory does not exist, create it.

  • ResNet-50 network model file (.prototxt): Click here to download the file.
  • ResNet-50 weight file (.caffemodel): Click here to download the file.