Creating an Image

Obtaining a Training Image

Use either of the following methods to obtain a training image:

  • (Recommended) Download the base training image with the matching driver version from Ascend image repository based on the system architecture (ARM/x86_64) and model framework (TensorFlow/PyTorch/MindSpore). Change the default user in the container to root based on the base training image. (In versions later than 21.0.4, the default user of the base training image is non-root.) The base image does not contain files such as the training script and code. During training, those files are directly mounted and mapped to the container.
  • Customize your own training image according to related content in Creating an Image.

You can rename the downloaded or created base training image, for example, training:v7.3.0.

Hardening an Image

You can perform security hardening on the downloaded or created base training image to improve the image security. For details, see Hardening Container Security.