ArmMachineLearningModelFactory.ImageModelSettingsClassification Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Settings used for training the model. For more information on the available settings please visit the official documentation: https://docs.microsoft.com/en-us/azure/machine-learning/how-to-auto-train-image-models.
public static Azure.ResourceManager.MachineLearning.Models.ImageModelSettingsClassification ImageModelSettingsClassification(string advancedSettings = default, bool? amsGradient = default, string augmentations = default, float? beta1 = default, float? beta2 = default, int? checkpointFrequency = default, Azure.ResourceManager.MachineLearning.Models.MachineLearningFlowModelJobInput checkpointModel = default, string checkpointRunId = default, bool? distributed = default, bool? earlyStopping = default, int? earlyStoppingDelay = default, int? earlyStoppingPatience = default, bool? enableOnnxNormalization = default, int? evaluationFrequency = default, int? gradientAccumulationStep = default, int? layersToFreeze = default, float? learningRate = default, Azure.ResourceManager.MachineLearning.Models.LearningRateScheduler? learningRateScheduler = default, string modelName = default, float? momentum = default, bool? nesterov = default, int? numberOfEpochs = default, int? numberOfWorkers = default, Azure.ResourceManager.MachineLearning.Models.StochasticOptimizer? optimizer = default, int? randomSeed = default, float? stepLRGamma = default, int? stepLRStepSize = default, int? trainingBatchSize = default, int? validationBatchSize = default, float? warmupCosineLRCycles = default, int? warmupCosineLRWarmupEpochs = default, float? weightDecay = default, int? trainingCropSize = default, int? validationCropSize = default, int? validationResizeSize = default, int? weightedLoss = default);
static member ImageModelSettingsClassification : string * Nullable<bool> * string * Nullable<single> * Nullable<single> * Nullable<int> * Azure.ResourceManager.MachineLearning.Models.MachineLearningFlowModelJobInput * string * Nullable<bool> * Nullable<bool> * Nullable<int> * Nullable<int> * Nullable<bool> * Nullable<int> * Nullable<int> * Nullable<int> * Nullable<single> * Nullable<Azure.ResourceManager.MachineLearning.Models.LearningRateScheduler> * string * Nullable<single> * Nullable<bool> * Nullable<int> * Nullable<int> * Nullable<Azure.ResourceManager.MachineLearning.Models.StochasticOptimizer> * Nullable<int> * Nullable<single> * Nullable<int> * Nullable<int> * Nullable<int> * Nullable<single> * Nullable<int> * Nullable<single> * Nullable<int> * Nullable<int> * Nullable<int> * Nullable<int> -> Azure.ResourceManager.MachineLearning.Models.ImageModelSettingsClassification
Public Shared Function ImageModelSettingsClassification (Optional advancedSettings As String = Nothing, Optional amsGradient As Nullable(Of Boolean) = Nothing, Optional augmentations As String = Nothing, Optional beta1 As Nullable(Of Single) = Nothing, Optional beta2 As Nullable(Of Single) = Nothing, Optional checkpointFrequency As Nullable(Of Integer) = Nothing, Optional checkpointModel As MachineLearningFlowModelJobInput = Nothing, Optional checkpointRunId As String = Nothing, Optional distributed As Nullable(Of Boolean) = Nothing, Optional earlyStopping As Nullable(Of Boolean) = Nothing, Optional earlyStoppingDelay As Nullable(Of Integer) = Nothing, Optional earlyStoppingPatience As Nullable(Of Integer) = Nothing, Optional enableOnnxNormalization As Nullable(Of Boolean) = Nothing, Optional evaluationFrequency As Nullable(Of Integer) = Nothing, Optional gradientAccumulationStep As Nullable(Of Integer) = Nothing, Optional layersToFreeze As Nullable(Of Integer) = Nothing, Optional learningRate As Nullable(Of Single) = Nothing, Optional learningRateScheduler As Nullable(Of LearningRateScheduler) = Nothing, Optional modelName As String = Nothing, Optional momentum As Nullable(Of Single) = Nothing, Optional nesterov As Nullable(Of Boolean) = Nothing, Optional numberOfEpochs As Nullable(Of Integer) = Nothing, Optional numberOfWorkers As Nullable(Of Integer) = Nothing, Optional optimizer As Nullable(Of StochasticOptimizer) = Nothing, Optional randomSeed As Nullable(Of Integer) = Nothing, Optional stepLRGamma As Nullable(Of Single) = Nothing, Optional stepLRStepSize As Nullable(Of Integer) = Nothing, Optional trainingBatchSize As Nullable(Of Integer) = Nothing, Optional validationBatchSize As Nullable(Of Integer) = Nothing, Optional warmupCosineLRCycles As Nullable(Of Single) = Nothing, Optional warmupCosineLRWarmupEpochs As Nullable(Of Integer) = Nothing, Optional weightDecay As Nullable(Of Single) = Nothing, Optional trainingCropSize As Nullable(Of Integer) = Nothing, Optional validationCropSize As Nullable(Of Integer) = Nothing, Optional validationResizeSize As Nullable(Of Integer) = Nothing, Optional weightedLoss As Nullable(Of Integer) = Nothing) As ImageModelSettingsClassification
Parameters
- advancedSettings
- String
Settings for advanced scenarios.
- augmentations
- String
Settings for using Augmentations.
Value of 'beta1' when optimizer is 'adam' or 'adamw'. Must be a float in the range [0, 1].
Value of 'beta2' when optimizer is 'adam' or 'adamw'. Must be a float in the range [0, 1].
Frequency to store model checkpoints. Must be a positive integer.
- checkpointModel
- MachineLearningFlowModelJobInput
The pretrained checkpoint model for incremental training.
- checkpointRunId
- String
The id of a previous run that has a pretrained checkpoint for incremental training.
Minimum number of epochs or validation evaluations to wait before primary metric improvement is tracked for early stopping. Must be a positive integer.
Minimum number of epochs or validation evaluations with no primary metric improvement before the run is stopped. Must be a positive integer.
Frequency to evaluate validation dataset to get metric scores. Must be a positive integer.
Gradient accumulation means running a configured number of "GradAccumulationStep" steps without updating the model weights while accumulating the gradients of those steps, and then using the accumulated gradients to compute the weight updates. Must be a positive integer.
Number of layers to freeze for the model. Must be a positive integer. For instance, passing 2 as value for 'seresnext' means freezing layer0 and layer1. For a full list of models supported and details on layer freeze, please see: https://docs.microsoft.com/en-us/azure/machine-learning/how-to-auto-train-image-models.
- learningRateScheduler
- Nullable<LearningRateScheduler>
Learning rate scheduler enum.
- modelName
- String
Name of the model to use for training. For more information on the available models please visit the official documentation: https://docs.microsoft.com/en-us/azure/machine-learning/how-to-auto-train-image-models.
Value of momentum when optimizer is 'sgd'. Must be a float in the range [0, 1].
- optimizer
- Nullable<StochasticOptimizer>
Stochastic optimizer for image models.
Value of gamma when learning rate scheduler is 'step'. Must be a float in the range [0, 1].
Value of step size when learning rate scheduler is 'step'. Must be a positive integer.
Value of cosine cycle when learning rate scheduler is 'warmup_cosine'. Must be a float in the range [0, 1].
Value of warmup epochs when learning rate scheduler is 'warmup_cosine'. Must be a positive integer.
Value of weight decay when optimizer is 'sgd', 'adam', or 'adamw'. Must be a float in the range[0, 1].
Image crop size that is input to the neural network for the training dataset. Must be a positive integer.
Image crop size that is input to the neural network for the validation dataset. Must be a positive integer.
Image size to which to resize before cropping for validation dataset. Must be a positive integer.
Weighted loss. The accepted values are 0 for no weighted loss. 1 for weighted loss with sqrt.(class_weights). 2 for weighted loss with class_weights. Must be 0 or 1 or 2.
Returns
A new ImageModelSettingsClassification instance for mocking.