

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# 啟動標籤驗證或調整工作 (API)
<a name="sms-data-verify-start-api"></a>

啟動標籤驗證或調整工作，方法為串連成功完成的工作，或使用 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html) 作業從頭啟動新工作。該程序與用 `CreateLabelingJob` 設定新標籤工作幾乎相同，只需進行一些修改。請使用以下各節，了解串連標籤工作以建立調整或驗證標籤工作時，需要進行哪些修改。

使用 Ground Truth API 建立調整或驗證標籤工作時，您*必須*使用與原始標籤工作不同的 `LabelAttributeName`。原始標籤工作是用來建立您要調整或驗證之標籤的工作。

**重要**  
您為 `CreateLabelingJob` 的 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#SageMaker-CreateLabelingJob-request-LabelCategoryConfigS3Uri](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#SageMaker-CreateLabelingJob-request-LabelCategoryConfigS3Uri) 中的調整或驗證工作指定的標籤類別組態檔案，必須包含用於原始標籤工作的相同標籤。您可以新增標籤。對於 3D 點雲和影片影格工作，您還可以再新增標籤類別和影格屬性至標籤類別組態檔案。

## 邊界框和語意分割
<a name="sms-data-verify-start-api-image"></a>

若要建立邊界框或語意分割標籤驗證或調整工作，請使用下列指南來指定 `CreateLabelingJob` 作業的 API 屬性。
+ 使用 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#SageMaker-CreateLabelingJob-request-LabelAttributeName](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#SageMaker-CreateLabelingJob-request-LabelAttributeName) 參數，來指定要用於已驗證或已調整標籤的輸出標籤名稱。您必須使用與原始標籤工作所使用者不同的 `LabelAttributeName`。
+ 如果您正在串連工作，則會在自訂使用者介面範本中指定要調整或驗證之先前標籤工作中的標籤。若要了解如何建立自訂範本，請參閱[建立自訂工作者任務範本](a2i-custom-templates.md)。

  識別 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_UiConfig.html](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_UiConfig.html) 參數中使用者介面範本的位置。SageMaker AI 提供小工具，您可以在您的自訂範本中使用這些小工具來顯示舊標籤。使用下列其中一個 crowd 元素中的 `initial-value` 屬性來擷取需要驗證或調整的標籤，並將它們包含在您的任務範本中：
  + [crowd-semantic-segmentation](sms-ui-template-crowd-semantic-segmentation.md) — 在自訂使用者介面任務範本中請使用此 crowd 元素，來指定需要驗證或調整的語意分割標籤。
  + [crowd-bounding-box](sms-ui-template-crowd-bounding-box.md) — 在自訂使用者介面任務範本中請使用此 crowd 元素，來指定需要驗證或調整的邊界框標籤。
+ [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#SageMaker-CreateLabelingJob-request-LabelCategoryConfigS3Uri](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#SageMaker-CreateLabelingJob-request-LabelCategoryConfigS3Uri) 參數必須包含與前一個標籤工作相同的標籤類別。
+ 對於 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_HumanTaskConfig.html#sagemaker-Type-HumanTaskConfig-PreHumanTaskLambdaArn](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_HumanTaskConfig.html#sagemaker-Type-HumanTaskConfig-PreHumanTaskLambdaArn) 和 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_AnnotationConsolidationConfig.html#sagemaker-Type-AnnotationConsolidationConfig-AnnotationConsolidationLambdaArn](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_AnnotationConsolidationConfig.html#sagemaker-Type-AnnotationConsolidationConfig-AnnotationConsolidationLambdaArn)，請使用邊界框或語意分割調整或驗證 lambda ARN：
  + 對於邊界框，調整標籤工作 lambda 函式 ARN 結尾為 `AdjustmentBoundingBox`，驗證 lambda 函式 ARN 結尾為 `VerificationBoundingBox`。
  + 對於語意分割，調整標籤工作 lambda 函式 ARN 結尾為 `AdjustmentSemanticSegmentation`，驗證 lambda 函式 ARN 結尾為 `VerificationSemanticSegmentation`。

## 3D 點雲和影片影格
<a name="sms-data-verify-start-api-frame"></a>
+ 使用 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#SageMaker-CreateLabelingJob-request-LabelAttributeName](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#SageMaker-CreateLabelingJob-request-LabelAttributeName) 參數，來指定要用於已驗證或已調整標籤的輸出標籤名稱。您必須使用與原始標籤工作所使用者不同的 `LabelAttributeName`。
+ 您必須使用用於原始標籤工作的人工任務使用者介面 Amazon Resource Name (ARN) (`HumanTaskUiArn`)。若要查看支援的 ARN，請參閱 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_UiConfig.html#sagemaker-Type-UiConfig-HumanTaskUiArn](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_UiConfig.html#sagemaker-Type-UiConfig-HumanTaskUiArn)。
+ 在標籤類別組態檔案中，您必須指定先前標籤工作的標籤屬性名稱 ([https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#SageMaker-CreateLabelingJob-request-LabelAttributeName](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#SageMaker-CreateLabelingJob-request-LabelAttributeName))，那是您用來在 `auditLabelAttributeName` 參數中建立調整或驗證標籤工作的屬性名稱。
+ 您可以使用 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#SageMaker-CreateLabelingJob-request-LabelCategoryConfigS3Uri](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#SageMaker-CreateLabelingJob-request-LabelCategoryConfigS3Uri) 參數識別的標籤類別組態檔案中的 `editsAllowed` 參數，來指定標籤工作是*驗證*還是*調整*標籤工作。
  + 對於*驗證*標籤工作，您必須使用 `editsAllowed` 參數來指定所有標籤為無法修改。在 `labels` 中的每個項目 `editsAllowed` 必須設定為 `"none"`。或者，您可以指定工作者是否可以調整標籤類別屬性和影格屬性。
  + 對於*調整*標籤工作，您可以選擇使用 `editsAllowed` 參數來指定工作者可以或不可以修改的標籤、標籤類別屬性及影格屬性。如果不使用此參數，則所有所有標籤、標籤類別屬性和影格屬性都將可調整。

  若要進一步了解有關 `editsAllowed` 參數和設定標籤類別組態檔案，請參閱[標籤類別組態檔案結構描述](sms-label-cat-config-attributes.md#sms-label-cat-config-attributes-schema)。
+ 使用 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_HumanTaskConfig.html#sagemaker-Type-HumanTaskConfig-PreHumanTaskLambdaArn](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_HumanTaskConfig.html#sagemaker-Type-HumanTaskConfig-PreHumanTaskLambdaArn) 和 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_AnnotationConsolidationConfig.html#sagemaker-Type-AnnotationConsolidationConfig-AnnotationConsolidationLambdaArn](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_AnnotationConsolidationConfig.html#sagemaker-Type-AnnotationConsolidationConfig-AnnotationConsolidationLambdaArn) 的 3D 點雲或影片影格調整 lambda ARN 來進行調整和驗證標籤工作：
  + 3D 點雲的調整和驗證標籤工作 lambda 函式 ARN 的結尾為 `Adjustment3DPointCloudSemanticSegmentation`、`Adjustment3DPointCloudObjectTracking`，而 3D 點雲語意分割、物件偵測和物件追蹤的調整和驗證標籤工作 lambda 函式 ARN 結尾則為 `Adjustment3DPointCloudObjectDetection`。
  + 對於影片影格，影片影格物件偵測和物件追蹤的調整和驗證標籤工作 lambda 函式 ARN 的結尾分別為 `AdjustmentVideoObjectDetection` 和 `AdjustmentVideoObjectTracking`。

Ground Truth 會將標籤驗證或調整工作的輸出資料儲存在您在 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html) 作業中的 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_LabelingJobOutputConfig.html#SageMaker-Type-LabelingJobOutputConfig-S3OutputPath](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_LabelingJobOutputConfig.html#SageMaker-Type-LabelingJobOutputConfig-S3OutputPath) 參數所指定的 S3 儲存貯體中。如需來自標籤驗證或調整標籤工作之輸出資料的詳細資訊，請參閱[輸出資訊清單中的標籤驗證和調整資料](sms-data-verify-manifest.md)。