다음을 통해 공유


ILearningModelVariableDescriptorPreview.Name 속성

정의

더 이상 사용되지 않습니다. 변수의 이름을 가져옵니다.

public:
 property Platform::String ^ Name { Platform::String ^ get(); };
winrt::hstring Name();
/// [get: Windows.Foundation.Metadata.Deprecated("Use ILearningModelFeatureDescriptor instead of ILearningModelVariableDescriptorPreview. For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 131072, "Windows.AI.MachineLearning.Preview.MachineLearningPreviewContract")]
winrt::hstring Name();
public string Name { get; }
public string Name { [Windows.Foundation.Metadata.Deprecated("Use ILearningModelFeatureDescriptor instead of ILearningModelVariableDescriptorPreview. For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 131072, "Windows.AI.MachineLearning.Preview.MachineLearningPreviewContract")] get; }
var string = iLearningModelVariableDescriptorPreview.name;
Public ReadOnly Property Name As String

속성 값

String

Platform::String

winrt::hstring

변수의 이름입니다.

특성

예제

public void Evaluator(LearningModelPreview model)
{
	// Retrieve the first input feature which is an image
    ILearningModelVariableDescriptorPreview inputImageFeatureDescription = model.Description.InputFeatures.FirstOrDefault(feature=>feature.ModelFeatureKind == LearningModelFeatureKindPreview.Image);

    ImageVariableDescriptorPreview imageDescriptor = (ImageVariableDescriptorPreview)inputImageFeatureDescription;

	// Ensure the input feature has the specified name "data"
    if (imageDescriptor.Name == "data")
    {
        Console.WriteLine($"Verified. Input variable name is: {imageDescriptor.Name}");
    }
 }

설명

경고

더 이상 사용되지 않는 API입니다. 대신 Windows.AI.MachineLearning 네임스페이스를 사용하세요.

이름은 모델의 다른 모든 변수에서 고유해야 합니다.

적용 대상