Updated on 2024-04-01 GMT+08:00

Preparing Data

Before using ModelArts ExeML to build a model, upload data to an OBS bucket. The OBS bucket and ModelArts must be in the same region.

Requirements for Sound Classification Data

  • Only 16-bit WAV files are supported. All sub-formats of WAV are supported.
  • The audio must be longer than 1 second and the file must be no larger than 4 MB.
  • Add more sound files to improve model precision. Prepare at least 20 sound files for each class. Ensure that the total duration of each class is no shorter than 5 minutes.
  • Ensure that the sound files are authentic and cover all scenarios in real life.
  • The quality of the training set has a great impact on the precision of the model. Set the sampling rate to the precision of the training set.
  • The labeling quality has a great impact on the model precision. Do not mislabel objects.
  • Only Chinese and English are supported for audio labeling.

Uploading Data to OBS

In this section, the OBS console is used to upload data.

Upload files to OBS according to the following specifications:

  • If you do not need to upload training data in advance, create an empty folder to store files generated in the future, for example, /bucketName/data-cat.
  • If you need to upload training data in advance, create an empty folder, and save the sound files to be labeled in the folder, for example, /bucketName/data-cat/cat.wav.

Procedure for uploading data to OBS:

Perform the following operations to import data to the dataset for model training and building.

  1. Log in to the OBS console and create a bucket in the same region as ModelArts. If an available bucket exists, ensure that the OBS bucket and ModelArts are in the same region.
  2. Upload the local data to the OBS bucket. If you have a large amount of data, use OBS Browser+ to upload data or folders. The uploaded data must meet the dataset requirements of the ExeML project.
  • Upload data from unencrypted buckets. Otherwise, training will fail because data cannot be decrypted.
  • Training sound files must be classified into at least two classes, and each class must contain at least 20 sound files.

Creating a Dataset

After the data preparation is completed, create a dataset of the type supported by the project. For details, see Creating a Dataset.