您现在访问的是微软AZURE全球版技术文档网站,若需要访问由世纪互联运营的MICROSOFT AZURE中国区技术文档网站,请访问 https://docs.azure.cn.

Update Image Metadata - Update Image Metadata

更新图像的元数据。
此 API 接受一批映像 ID 和元数据,以更新映像。 图像限制为 64 个。

POST {Endpoint}/customvision/v3.3/training/projects/{projectId}/images/metadata?imageIds={imageIds}

URI 参数

Name In Required Type Description
Endpoint
path True
  • string

支持的认知服务终结点。

projectId
path True
  • string
uuid

项目 ID。

imageIds
query True
  • array

要更新的图像 ID 列表。 限制为 64。

请求头

Media Types: "application/json", "application/xml", "text/xml", "application/x-www-form-urlencoded"

Name Required Type Description
Training-Key True
  • string

响应

Name Type Description
200 OK

确定

Media Types: "application/json", "application/xml", "text/xml"

Other Status Codes

207

Media Types: "application/json", "application/xml", "text/xml"

Other Status Codes

错误响应

Media Types: "application/json", "application/xml", "text/xml"

安全性

Training-Key

Type: apiKey
In: header

示例

Successful UpdateImageMetadata request

Sample Request

POST https://westus.api.cognitive.microsoft.com/customvision/v3.3/training/projects/bc3f7dad-5544-468c-8573-3ef04d55463e/images/metadata?imageIds=[

  "4d6eb844-42ee-42bc-bd6f-c32455ef07c9"

]
Training-Key: {API Key}
{
  "tag": "value"
}

Sample Response

{
  "isBatchSuccessful": true,
  "images": [
    {
      "imageId": "4d6eb844-42ee-42bc-bd6f-c32455ef07c9",
      "status": "OK",
      "metadata": {
        "tag": "value"
      }
    }
  ]
}
{
  "isBatchSuccessful": false,
  "images": [
    {
      "imageId": "4d6eb844-42ee-42bc-bd6f-c32455ef07c9",
      "status": "ErrorLimitExceed"
    }
  ]
}

定义

CustomVisionError
CustomVisionErrorCodes

错误代码。

ImageMetadataUpdateEntry

将元数据与图像关联的项。

ImageMetadataUpdateStatus

元数据更新的状态。

ImageMetadataUpdateSummary

CustomVisionError

Name Type Description
code

错误代码。

message
  • string

一条消息,说明服务报告的错误。

CustomVisionErrorCodes

错误代码。

Name Type Description
BadRequest
  • string
BadRequestCannotMigrateProjectWithName
  • string
BadRequestClassificationTrainingValidationFailed
  • string
BadRequestCustomerManagedKeyRevoked
  • string
BadRequestDetectionTrainingNotAllowNegativeTag
  • string
BadRequestDetectionTrainingValidationFailed
  • string
BadRequestDomainNotSupportedForAdvancedTraining
  • string
BadRequestExceedIterationPerProjectLimit
  • string
BadRequestExceedProjectLimit
  • string
BadRequestExceedTagPerImageLimit
  • string
BadRequestExceedTagPerProjectLimit
  • string
BadRequestExceededBatchSize
  • string
BadRequestExceededQuota
  • string
BadRequestExportAlreadyInProgress
  • string
BadRequestExportPlatformNotSupportedForAdvancedTraining
  • string
BadRequestExportValidationFailed
  • string
BadRequestExportWhileTraining
  • string
BadRequestImageBatch
  • string
BadRequestImageDimensions
  • string
BadRequestImageExceededCount
  • string
BadRequestImageFormat
  • string
BadRequestImageMetadataKey
  • string
BadRequestImageMetadataValue
  • string
BadRequestImageRegions
  • string
BadRequestImageSizeBytes
  • string
BadRequestImageStream
  • string
BadRequestImageTags
  • string
BadRequestImageUrl
  • string
BadRequestInvalid
  • string
BadRequestInvalidArtifactUri
  • string
BadRequestInvalidEmailAddress
  • string
BadRequestInvalidIds
  • string
BadRequestInvalidImportToken
  • string
BadRequestInvalidPublishName
  • string
BadRequestInvalidPublishTarget
  • string
BadRequestIterationDescription
  • string
BadRequestIterationIsNotTrained
  • string
BadRequestIterationIsPublished
  • string
BadRequestIterationName
  • string
BadRequestIterationNameNotUnique
  • string
BadRequestIterationNotPublished
  • string
BadRequestIterationValidationFailed
  • string
BadRequestMultiClassClassificationTrainingValidationFailed
  • string
BadRequestMultiLabelClassificationTrainingValidationFailed
  • string
BadRequestMultipleGeneralProductTag
  • string
BadRequestMultipleNegativeTag
  • string
BadRequestNegativeAndRegularTagOnSameImage
  • string
BadRequestNotLimitedTrial
  • string
BadRequestNotSupported
  • string
BadRequestOperationNotSupported
  • string
BadRequestPredictionIdsExceededCount
  • string
BadRequestPredictionIdsMissing
  • string
BadRequestPredictionInvalidApplicationName
  • string
BadRequestPredictionInvalidQueryParameters
  • string
BadRequestPredictionResultsExceededCount
  • string
BadRequestPredictionTagsExceededCount
  • string
BadRequestProjectDescription
  • string
BadRequestProjectDuplicated
  • string
BadRequestProjectImagePreprocessingSettings
  • string
BadRequestProjectName
  • string
BadRequestProjectNameNotUnique
  • string
BadRequestProjectUnknownClassification
  • string
BadRequestProjectUnknownDomain
  • string
BadRequestProjectUnsupportedDomainTypeChange
  • string
BadRequestProjectUnsupportedExportPlatform
  • string
BadRequestRequiredParamIsNull
  • string
BadRequestReservedBudgetInHoursNotEnoughForAdvancedTraining
  • string
BadRequestSubscriptionApi
  • string
BadRequestTagDescription
  • string
BadRequestTagName
  • string
BadRequestTagNameNotUnique
  • string
BadRequestTagType
  • string
BadRequestTrainingAlreadyInProgress
  • string
BadRequestTrainingNotNeeded
  • string
BadRequestTrainingNotNeededButTrainingPipelineUpdated
  • string
BadRequestTrainingValidationFailed
  • string
BadRequestUnpublishFailed
  • string
BadRequestUnsupportedDomain
  • string
BadRequestWorkspaceCannotBeModified
  • string
BadRequestWorkspaceNotDeletable
  • string
Conflict
  • string
ConflictInvalid
  • string
ErrorExporterInvalidClassifier
  • string
ErrorExporterInvalidFeaturizer
  • string
ErrorExporterInvalidPlatform
  • string
ErrorFeaturizationAugmentationError
  • string
ErrorFeaturizationAugmentationUnavailable
  • string
ErrorFeaturizationInvalidFeaturizer
  • string
ErrorFeaturizationQueueTimeout
  • string
ErrorFeaturizationServiceUnavailable
  • string
ErrorFeaturizationUnrecognizedJob
  • string
ErrorInvalid
  • string
ErrorIterationCopyFailed
  • string
ErrorPrediction
  • string
ErrorPredictionModelNotCached
  • string
ErrorPredictionModelNotFound
  • string
ErrorPredictionServiceUnavailable
  • string
ErrorPredictionStorage
  • string
ErrorPreparePerformanceMigrationFailed
  • string
ErrorProjectExportRequestFailed
  • string
ErrorProjectImportRequestFailed
  • string
ErrorProjectInvalidDomain
  • string
ErrorProjectInvalidPipelineConfiguration
  • string
ErrorProjectInvalidWorkspace
  • string
ErrorProjectTrainingRequestFailed
  • string
ErrorRegionProposal
  • string
ErrorUnknown
  • string
ErrorUnknownBaseModel
  • string
Forbidden
  • string
ForbiddenDRModeEnabled
  • string
ForbiddenInvalid
  • string
ForbiddenUser
  • string
ForbiddenUserDisabled
  • string
ForbiddenUserDoesNotExist
  • string
ForbiddenUserInsufficientCapability
  • string
ForbiddenUserResource
  • string
ForbiddenUserSignupAllowanceExceeded
  • string
ForbiddenUserSignupDisabled
  • string
NoError
  • string
NotFound
  • string
NotFoundApimSubscription
  • string
NotFoundDomain
  • string
NotFoundImage
  • string
NotFoundInvalid
  • string
NotFoundIteration
  • string
NotFoundIterationPerformance
  • string
NotFoundProject
  • string
NotFoundProjectDefaultIteration
  • string
NotFoundTag
  • string
UnsupportedMediaType
  • string

ImageMetadataUpdateEntry

将元数据与图像关联的项。

Name Type Description
imageId
  • string

映像的 ID。

metadata
  • object

图像的元数据。

status

元数据更新的状态。

ImageMetadataUpdateStatus

元数据更新的状态。

Name Type Description
ErrorImageNotFound
  • string
ErrorLimitExceed
  • string
ErrorUnknown
  • string
OK
  • string

ImageMetadataUpdateSummary

Name Type Description
images

将元数据与图像关联的项。

isBatchSuccessful
  • boolean