Skip to content

Commit d057f1c

Browse files
authored
Documented the flag to toggle the OD & IS Augs
1 parent 8c3fc09 commit d057f1c

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

articles/machine-learning/how-to-auto-train-image-models.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -533,6 +533,32 @@ In general, deep learning model performance can often improve with more data. Da
533533
|Object detection, instance segmentation| Training <br><br> Validation & Test |Random crop around bounding boxes, expand, horizontal flip, normalization, resize <br><br><br>Normalization, resize
534534
|Object detection using yolov5| Training <br><br> Validation & Test |Mosaic, random affine (rotation, translation, scale, shear), horizontal flip <br><br><br> Letterbox resizing|
535535

536+
Currently the augmentations defined above are applied by default for an Automated ML job. To facilitate a better control over the augmentations, Automated ML expose flags to turn-off certain train time augmentations. Currently, these flags are only supported for object detection and instance segmentation tasks. We expose following two flags to turn-off the augmentations.
537+
1. **apply_mosaic_for_yolo:** This flag is only specific to Yolo model and turns off the mosaic data augmentation which is applied at the train time.
538+
2. **apply_automl_train_augmentations:** This flag turns off the augmentation applied at the train time to the object detection and instance segmentation models. For augmentations, please see the details in the table above. Please note that for non-yolo object detection models and instance segmentation model, this flag turns off only first three augmentations i.e. *Random crop around bounding boxes, expand, horizontal flip*. The normalization and resize augmentation is still applied regardless of this flag.
539+
For Yolo model, this flag turns off the random affine and horizontal flg augmentation.
540+
541+
These two flags are supported via *advanced_settings* under *training_parameters* and can be controlled in the following way.
542+
# [Azure CLI](#tab/cli)
543+
544+
[!INCLUDE [cli v2](../../includes/machine-learning-cli-v2.md)]
545+
546+
```yaml
547+
training_parameters:
548+
advanced_settings: >
549+
{"apply_mosaic_for_yolo": false}
550+
```
551+
```yaml
552+
training_parameters:
553+
advanced_settings: >
554+
{"apply_automl_train_augmentations": false}
555+
```
556+
Please note that these two flags are independent of each other and can also be used in combination using the following settings.
557+
```yaml
558+
training_parameters:
559+
advanced_settings: >
560+
{"apply_automl_train_augmentations": false, "apply_mosaic_for_yolo": false}
561+
```
536562
## Incremental training (optional)
537563

538564
Once the training run is done, you have the option to further train the model by loading the trained model checkpoint. You can either use the same dataset or a different one for incremental training.

0 commit comments

Comments
 (0)