Structure

MLActivityClassifier.ModelParameters

Parameters that affect the process of training an activity classification model.

Declaration

struct MLActivityClassifier.ModelParameters

Topics

Creating Parameters

init(validationData: MLActivityClassifier.DataSource, batchSize: Int?, maximumIterations: Int?, predictionWindowSize: Int?)

Creates a new set of activity classifier parameters with validation data represented by a data source.

init(validationData: MLDataTable?, batchSize: Int?, maximumIterations: Int?, predictionWindowSize: Int?)

Creates a new set of activity classifier parameters with validation data represented by a data table.

Validating the Model

var validationData: MLDataTable?

Activity data the training process uses for validation.

Configuring Model Training

var batchSize: Int?

The number of sequence chunks the model uses per training iteration.

var maximumIterations: Int?

The maximum number of iterations over the training data the model should perform during training.

var predictionWindowSize: Int?

The number of samples for each labelled activity.

Describing Parameters

var description: String

A text representation of the model parameters.

var debugDescription: String

A text representation of the model parameters that’s suitable for output during debugging.

var playgroundDescription: Any

A description of the model parameters shown in a playground.

See Also

Creating and Training an Activity Classifier

enum MLActivityClassifier.DataSource

A data source for an activity classifier.

let modelParameters: MLActivityClassifier.ModelParameters

The configuration parameters that the activity classifier used for training during initialization.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software