Compartilhar via


AnomalyDetectorClient.GetMultivariateModelsAsync Método

Definição

Sobrecargas

GetMultivariateModelsAsync(Nullable<Int32>, Nullable<Int32>, RequestContext)

[Método de protocolo] Listar modelos multivariados

GetMultivariateModelsAsync(Nullable<Int32>, Nullable<Int32>, CancellationToken)

Listar modelos multivariados.

GetMultivariateModelsAsync(Nullable<Int32>, Nullable<Int32>, RequestContext)

Origem:
AnomalyDetectorClient.cs

[Método de protocolo] Listar modelos multivariados

public virtual Azure.AsyncPageable<BinaryData> GetMultivariateModelsAsync (int? skip, int? maxCount, Azure.RequestContext context);
abstract member GetMultivariateModelsAsync : Nullable<int> * Nullable<int> * Azure.RequestContext -> Azure.AsyncPageable<BinaryData>
override this.GetMultivariateModelsAsync : Nullable<int> * Nullable<int> * Azure.RequestContext -> Azure.AsyncPageable<BinaryData>
Public Overridable Function GetMultivariateModelsAsync (skip As Nullable(Of Integer), maxCount As Nullable(Of Integer), context As RequestContext) As AsyncPageable(Of BinaryData)

Parâmetros

skip
Nullable<Int32>

O número de itens de resultado a serem ignoradas.

maxCount
Nullable<Int32>

O número de itens de resultado a serem retornados.

context
RequestContext

O contexto de solicitação, que pode substituir os comportamentos padrão do pipeline do cliente por chamada.

Retornos

O AsyncPageable<T> do serviço que contém uma lista de BinaryData objetos. Os detalhes do esquema do corpo de cada item na coleção estão na seção Comentários abaixo.

Exceções

O serviço retornou um código de status sem êxito.

Exemplos

Este exemplo mostra como chamar GetMultivariateModelsAsync com os parâmetros necessários e analisar o resultado.

var credential = new AzureKeyCredential("<key>");
var endpoint = new Uri("<https://my-service.azure.com>");
var client = new AnomalyDetectorClient(endpoint, credential);

await foreach (var item in client.GetMultivariateModelsAsync(1234, 1234, new RequestContext()))
{
    JsonElement result = JsonDocument.Parse(item.ToStream()).RootElement;
    Console.WriteLine(result.GetProperty("modelId").ToString());
    Console.WriteLine(result.GetProperty("createdTime").ToString());
    Console.WriteLine(result.GetProperty("lastUpdatedTime").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("dataSource").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("dataSchema").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("startTime").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("endTime").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("displayName").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("slidingWindow").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("alignPolicy").GetProperty("alignMode").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("alignPolicy").GetProperty("fillNAMethod").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("alignPolicy").GetProperty("paddingValue").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("status").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("errors")[0].GetProperty("code").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("errors")[0].GetProperty("message").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("diagnosticsInfo").GetProperty("modelState").GetProperty("epochIds")[0].ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("diagnosticsInfo").GetProperty("modelState").GetProperty("trainLosses")[0].ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("diagnosticsInfo").GetProperty("modelState").GetProperty("validationLosses")[0].ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("diagnosticsInfo").GetProperty("modelState").GetProperty("latenciesInSeconds")[0].ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("diagnosticsInfo").GetProperty("variableStates")[0].GetProperty("variable").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("diagnosticsInfo").GetProperty("variableStates")[0].GetProperty("filledNARatio").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("diagnosticsInfo").GetProperty("variableStates")[0].GetProperty("effectiveCount").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("diagnosticsInfo").GetProperty("variableStates")[0].GetProperty("firstTimestamp").ToString());
    Console.WriteLine(result.GetProperty("modelInfo").GetProperty("diagnosticsInfo").GetProperty("variableStates")[0].GetProperty("lastTimestamp").ToString());
}

Comentários

Listar modelos de um recurso.

Abaixo está o esquema JSON para um item na resposta paginável.

Corpo da resposta:

Esquema para Array:

{
  modelId: string, # Required.
  createdTime: string (date & time), # Required.
  lastUpdatedTime: string (date & time), # Required.
  modelInfo: {
    dataSource: string, # Required.
    dataSchema: "OneTable" | "MultiTable", # Optional.
    startTime: string (date & time), # Required.
    endTime: string (date & time), # Required.
    displayName: string, # Optional.
    slidingWindow: number, # Optional.
    alignPolicy: {
      alignMode: "Inner" | "Outer", # Optional.
      fillNAMethod: "Previous" | "Subsequent" | "Linear" | "Zero" | "Fixed", # Optional.
      paddingValue: number, # Optional.
    }, # Optional.
    status: "CREATED" | "RUNNING" | "READY" | "FAILED", # Optional.
    errors: [ErrorResponse], # Optional.
    diagnosticsInfo: {
      modelState: {
        epochIds: [number], # Optional.
        trainLosses: [number], # Optional.
        validationLosses: [number], # Optional.
        latenciesInSeconds: [number], # Optional.
      }, # Optional.
      variableStates: [VariableState], # Optional.
    }, # Optional.
  }, # Optional.
}

Aplica-se a

GetMultivariateModelsAsync(Nullable<Int32>, Nullable<Int32>, CancellationToken)

Origem:
AnomalyDetectorClient.cs

Listar modelos multivariados.

public virtual Azure.AsyncPageable<Azure.AI.AnomalyDetector.AnomalyDetectionModel> GetMultivariateModelsAsync (int? skip = default, int? maxCount = default, System.Threading.CancellationToken cancellationToken = default);
abstract member GetMultivariateModelsAsync : Nullable<int> * Nullable<int> * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.AI.AnomalyDetector.AnomalyDetectionModel>
override this.GetMultivariateModelsAsync : Nullable<int> * Nullable<int> * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.AI.AnomalyDetector.AnomalyDetectionModel>
Public Overridable Function GetMultivariateModelsAsync (Optional skip As Nullable(Of Integer) = Nothing, Optional maxCount As Nullable(Of Integer) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As AsyncPageable(Of AnomalyDetectionModel)

Parâmetros

skip
Nullable<Int32>

O número de itens de resultado a serem ignoradas.

maxCount
Nullable<Int32>

O número de itens de resultado a serem retornados.

cancellationToken
CancellationToken

O token de cancelamento a ser usado.

Retornos

Exemplos

Este exemplo mostra como chamar GetMultivariateModelsAsync com os parâmetros necessários.

var credential = new AzureKeyCredential("<key>");
var endpoint = new Uri("<https://my-service.azure.com>");
var client = new AnomalyDetectorClient(endpoint, credential);

await foreach (var item in client.GetMultivariateModelsAsync(1234, 1234))
{
}

Comentários

Listar modelos de um recurso.

Aplica-se a