Share via


LearningModel.LoadFromStream Method

Definition

Overloads

LoadFromStream(IRandomAccessStreamReference)

Important

For the latest documentation about Windows Machine Learning, see What is Windows ML. That documentation describes APIs that are in the Microsoft.Windows.AI.MachineLearning namespace, which ships in the Windows App SDK. Those APIs supersede the ones documented here, which are in the Windows.AI.MachineLearning namespace, and were shipped in 2018.

Loads an ONNX model from a stream.

LoadFromStream(IRandomAccessStreamReference, ILearningModelOperatorProvider)

Important

For the latest documentation about Windows Machine Learning, see What is Windows ML. That documentation describes APIs that are in the Microsoft.Windows.AI.MachineLearning namespace, which ships in the Windows App SDK. Those APIs supersede the ones documented here, which are in the Windows.AI.MachineLearning namespace, and were shipped in 2018.

Loads an ONNX model from a stream.

LoadFromStream(IRandomAccessStreamReference)

Important

For the latest documentation about Windows Machine Learning, see What is Windows ML. That documentation describes APIs that are in the Microsoft.Windows.AI.MachineLearning namespace, which ships in the Windows App SDK. Those APIs supersede the ones documented here, which are in the Windows.AI.MachineLearning namespace, and were shipped in 2018.

Loads an ONNX model from a stream.

public:
 static LearningModel ^ LoadFromStream(IRandomAccessStreamReference ^ modelStream);
/// [Windows.Foundation.Metadata.Overload("LoadFromStream")]
 static LearningModel LoadFromStream(IRandomAccessStreamReference const& modelStream);
[Windows.Foundation.Metadata.Overload("LoadFromStream")]
public static LearningModel LoadFromStream(IRandomAccessStreamReference modelStream);
function loadFromStream(modelStream)
Public Shared Function LoadFromStream (modelStream As IRandomAccessStreamReference) As LearningModel

Parameters

modelStream
IRandomAccessStreamReference

The stream from which to load the model.

Returns

An object representing the model file.

Attributes

Remarks

Windows Server

To use this API on Windows Server, you must use Windows Server 2019 with Desktop Experience.

Thread safety

This API is thread-safe.

Applies to

LoadFromStream(IRandomAccessStreamReference, ILearningModelOperatorProvider)

Important

For the latest documentation about Windows Machine Learning, see What is Windows ML. That documentation describes APIs that are in the Microsoft.Windows.AI.MachineLearning namespace, which ships in the Windows App SDK. Those APIs supersede the ones documented here, which are in the Windows.AI.MachineLearning namespace, and were shipped in 2018.

Loads an ONNX model from a stream.

public:
 static LearningModel ^ LoadFromStream(IRandomAccessStreamReference ^ modelStream, ILearningModelOperatorProvider ^ operatorProvider);
/// [Windows.Foundation.Metadata.Overload("LoadFromStreamWithOperatorProvider")]
 static LearningModel LoadFromStream(IRandomAccessStreamReference const& modelStream, ILearningModelOperatorProvider const& operatorProvider);
[Windows.Foundation.Metadata.Overload("LoadFromStreamWithOperatorProvider")]
public static LearningModel LoadFromStream(IRandomAccessStreamReference modelStream, ILearningModelOperatorProvider operatorProvider);
function loadFromStream(modelStream, operatorProvider)
Public Shared Function LoadFromStream (modelStream As IRandomAccessStreamReference, operatorProvider As ILearningModelOperatorProvider) As LearningModel

Parameters

modelStream
IRandomAccessStreamReference

The stream from which to load the model.

Returns

An object representing the model file.

Attributes

Remarks

Windows Server

To use this API on Windows Server, you must use Windows Server 2019 with Desktop Experience.

Thread safety

This API is thread-safe.

Applies to