Skip to content

Training on openi

MindOCR OpenI Training Guideline

This tutorial introduces the training method of MindOCR using the OpenI platform.

Clone the project

Click on the plus sign and choose to New Migration to clone MindOCR from GitHub to the Openi platform.

Enter the MindOCR git url: https://github.com/mindspore-lab/mindocr.git

Prepare Dataset

You can upload your own dataset or associate the project with existing datasets on the platform.

Uploading personal datasets requires setting the available clusters to NPU.

Prepare pretrained model (optional)

To upload pre-trained weights, choose the Model tab of your repository.

During the import of a local model, set the model's framework to MindSpore.

New Training Task

Select Training Task -> New Training Task in the Cloudbrain tab.

In computing resources choose Ascend NPU.

Set the training entry point (Start File) and add run parameters.

  • To load pre-trained weights, choose the uploaded previously model file in the Select Model field and add ckpt_dir to the run parameters. The ckpt_dir parameter must have the following path: /cache/*.ckpt, where * is the model's file name.
  • In the AI engine, it is necessary to select MindSpore version 1.9 or higher, and set the start file to tools/train.py
  • :warning: It is necessary to set enable_modelarts to True in the run parameters.
  • The model's architecture is specified in the config file set in the run parameters. The prefix of the file is always /home/work/user-job-dir/run-version-number, where run-version-number for the newly created training task is usually V0001.

Modify existing training tasks

Click the modify button of an existing training task to modify its parameters and run a new training task.

Note: run-version-number will change to Parents Version (current run version number) + 1, e.g. V0002.

View training status

Select a training task to view configuration information, logs, resource occupancy, and download model weights.

Reference

[1] Modified from https://github.com/mindspore-lab/mindyolo/blob/master/tutorials/cloud/openi.md