

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

# 建立 3D-2D 點雲物件追蹤標籤工作
<a name="sms-3d-2d-point-cloud-object-tracking-create-labeling-job"></a>

您可以使用 SageMaker API 作業，[https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html)建立 3D-2D 點雲標籤工作。若要為此任務類型建立標籤工作，您需要下列項目：
+ 由私有或廠商人力資源組成的工作團隊。您不能使用 Amazon Mechanical Turk 來處理 3D 點雲標籤工作。若要了解如何建立人力資源和工作團隊，請參閱[人力資源](sms-workforce-management.md)。
+ 在 Amazon S3 主控台將 CORS 政策新增至包含輸入資料的 S3 儲存貯體。若要在 S3 主控台，在包含輸入映像的 S3 儲存貯體設定需要的 CORS 標題，請按照 [CORS 許可要求](https://docs.aws.amazon.com/sagemaker/latest/dg/sms-cors-update.html)的詳細說明操作。
+ 此外，請確定您已檢閱且符合[指派 IAM 許可以使用 Ground Truth](sms-security-permission.md)。

若要了解如何使用 API 建立標籤工作，請參閱下列各節。

## 建立標籤工作 (API)
<a name="sms-point-cloud-3d-2d-object-tracking-create-labeling-job-api"></a>

本節涵蓋使用 SageMaker API 作業 `CreateLabelingJob` 建立 3D-2D 物件追蹤標籤工作時，您需要知道的詳細資訊。此 API 會定義 AWS SDKs此操作。若要查看這項作業支援的特定語言 SDK 清單，請參閱 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html) 的**另請參閱**章節。

[建立標籤工作 (API)](sms-create-labeling-job-api.md)提供 `CreateLabelingJob` 作業的概觀。設定請求時，請遵循這些指示並執行下列動作：
+ 您必須在 `HumanTaskUiArn` 中輸入 ARN。請使用 `arn:aws:sagemaker:{{<region>}}:394669845002:human-task-ui/PointCloudObjectTracking`。將 `{{<region>}}` 取代為您建立標籤工作所在的 AWS 區域。

  請勿輸入 `UiTemplateS3Uri` 參數。
+ [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) 的結尾必須是 `-ref`。例如 `{{ot-labels}}-ref`。
+ 輸入資訊清單檔案必須是點雲影格序列資訊清單檔案。如需詳細資訊，請參閱[建立點雲序列輸入資訊清單](sms-point-cloud-multi-frame-input-data.md)。您還需要提供如上所述的標籤類別組態檔案。
+ 您必須為註釋前和註釋後 (ACS) Lambda 函式提供預先定義的 ARN。這些 ARN 專屬於您用來建立標籤工作的 AWS 區域。
  + 若要尋找註釋前 Lambda ARN，請參閱 [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)。使用您建立標籤工作所在的區域，找出結尾是 `PRE-3DPointCloudObjectTracking` 的正確 ARN。
  + 若要尋找註釋後 Lambda ARN，請參閱 [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)。使用您建立標籤工作所在的區域，找出結尾是 `ACS-3DPointCloudObjectTracking` 的正確 ARN。
+ `NumberOfHumanWorkersPerDataObject` 中指定的工作者數目應該為 `1`。
+ 3D 點雲標籤工作不支援自動資料標籤。請勿在 `[LabelingJobAlgorithmsConfig](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html#sagemaker-CreateLabelingJob-request-LabelingJobAlgorithmsConfig)` 中指定參數的值。
+ 3D-2D 雲物件追蹤標籤工作可能需要數小時才能完成。您可以在 `TaskTimeLimitInSeconds` 中為這些標籤工作指定更長的時間限制 (最多 7 天，即 604,800 秒)。

**注意**  
在您成功建立 3D-2D 物件追蹤工作之後，它會顯示在主控台上的標籤工作下。工作的任務類型會顯示為**點雲物件追蹤**。

## 輸入資料格式
<a name="sms-point-cloud-3d-2d-object-tracking-input-data"></a>

您可以使用 SageMaker API 作業 [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateLabelingJob.html)，建立 3D-2D 物件追蹤工作。若要為此任務類型建立標籤工作，您需要下列項目：
+ 序列輸入資訊清單檔案。若要了解如何建立這種資訊清單檔案，請參閱[建立點雲序列輸入資訊清單](sms-point-cloud-multi-frame-input-data.md)。如果您是 Ground Truth 3D 點雲標籤模式的新使用者，建議您閱讀 [接受的原始 3D 資料格式](sms-point-cloud-raw-data-types.md)。
+ 請在標籤類別組態檔案中指定標籤、標籤類別、影格屬性和工作者指示。如需詳細資訊，請參閱[使用標籤類別和影格屬性建立標籤類別組態檔案](https://docs.aws.amazon.com/sagemaker/latest/dg/sms-label-cat-config-attributes.html)，了解如何建立這個檔案。以下實例顯示用於建立 3D-2D 物件追蹤工作的標籤類別組態檔案。

  ```
  {
      "document-version": "2020-03-01",
      "categoryGlobalAttributes": [
          {
              "name": "Occlusion",
              "description": "global attribute that applies to all label categories",
              "type": "string",
              "enum":[
                  "Partial",
                  "Full"
              ]
          }
      ],
      "labels":[
          {
              "label": "Car",
              "attributes": [
                  {
                      "name": "Type",
                      "type": "string",
                      "enum": [
                          "SUV",
                          "Sedan"
                      ]
                  } 
              ]
          },
          {
              "label": "Bus",
              "attributes": [
                  {
                      "name": "Size",
                      "type": "string",
                      "enum": [
                          "Large",
                          "Medium",
                          "Small"
                      ]
                  }
              ]
          }
      ],
      "instructions": {
          "shortIntroduction": "Draw a tight cuboid around objects after you select a category.",
          "fullIntroduction": "<p>Use this area to add more detailed worker instructions.</p>"
      },
      "annotationType": [
          {
              "type": "BoundingBox"
          },
          {
              "type": "Cuboid"
          }
      ]
  }
  ```
**注意**  
您需要在標籤類別組態檔案中提供 `BoundingBox` 和 `Cuboid` 作為註釋類型，才能建立 3D-2D 物件追蹤工作。