Class

MLPredictionOptions

The options available when making a prediction.

Declaration

class MLPredictionOptions : NSObject

Topics

Restricting Computation to the CPU

var usesCPUOnly: Bool

A Boolean value that indicates whether a prediction is computed using only the CPU.

Relationships

Inherits From

Conforms To

See Also

Making Predictions

func prediction(from: MLFeatureProvider) -> MLFeatureProvider

Predicts output feature values from the given input feature values.

func prediction(from: MLFeatureProvider, options: MLPredictionOptions) -> MLFeatureProvider

Predicts output feature values from the given input feature values and prediction options.

func predictions(fromBatch: MLBatchProvider) -> MLBatchProvider

Predicts output feature values from the given a batch of input feature values.

func predictions(from: MLBatchProvider, options: MLPredictionOptions) -> MLBatchProvider

Predicts output feature values from the given a batch of input feature values and prediction options.

protocol MLFeatureProvider

An interface that represents a collection of values for either a model's input or its output.

protocol MLBatchProvider

An interface that represents a collection of feature providers.

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