LearningModelPreview.Description 属性
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
已弃用。 获取已训练的机器学习模型的描述性元数据。
public:
property LearningModelDescriptionPreview ^ Description { LearningModelDescriptionPreview ^ get(); };
LearningModelDescriptionPreview Description();
/// [get: Windows.Foundation.Metadata.Deprecated("Use ILearningModel instead of ILearningModelPreview. For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 131072, "Windows.AI.MachineLearning.Preview.MachineLearningPreviewContract")]
LearningModelDescriptionPreview Description();
public LearningModelDescriptionPreview Description { get; }
public LearningModelDescriptionPreview Description { [Windows.Foundation.Metadata.Deprecated("Use ILearningModel instead of ILearningModelPreview. For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 131072, "Windows.AI.MachineLearning.Preview.MachineLearningPreviewContract")] get; }
var learningModelDescriptionPreview = learningModelPreview.description;
Public ReadOnly Property Description As LearningModelDescriptionPreview
属性值
机器学习模型的描述性元数据。
- 属性
示例
public async Task LoadModel()
{
var modelFile = await Windows.ApplicationModel.Package.Current.InstalledLocation.GetFileAsync("model.onnx");
LearningModelPreview model = await LearningModelPreview.LoadModelFromStorageFileAsync(modelFile);
// Confirm the version of the model is 1
if (model.Description.Version != 1)
{
...
}
}
注解
警告
这是一个已弃用的 API。 请改用 Windows.AI.MachineLearning 命名空间。