了解培訓和測試驗證結果清單 - Rekognition

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

了解培訓和測試驗證結果清單

在訓練期間,Amazon Rekognition 自訂標籤會建立驗證結果資訊清單,以保留非終端 JSON 行錯誤。驗證結果資訊清單是訓練和測試資料集的複本,並新增了錯誤資訊。訓練完成後,您可以存取驗證資訊清單。如需詳細資訊,請參閱取得驗證結果。Amazon Rekognition 自訂標籤也會建立資訊清單摘要,其中包含 JSON 行錯誤的概觀資訊,例如錯誤位置和 JSON 行錯誤計數。如需詳細資訊,請參閱了解資訊清單摘要

注意

只有在沒終端機清單檔錯誤有的情況下,才會建立驗證結果 (訓練與測試驗證結果資訊清單和資訊清單摘要)。

清單包含 JSON 行數據集中的每個圖像。在驗證結果清單中,JSON 行錯誤信息添加到發生錯誤的 JSON 行。

JSON 行錯誤是與單個圖像相關的非終端錯誤。非終端驗證錯誤可能會使整個 JSON 行或只有一部分無效。例如,如果 JSON 行中參照的影像不是 PNG 或 JPG 格式,就會發生錯錯誤 _ 無效影像誤,而且整個 JSON 行會從訓練中排除。使用其他有效的 JSON 行繼續訓練。

在 JSON 行中,錯誤可能意味著 JSON 行可以用於培訓。例如,如果與標籤相關聯的四個邊界框之一的左邊值為負值,則仍會使用其他有效的邊界方塊來訓練模型。針對無效的邊界方塊 (錯誤 _ 無效 _ 邊界 _ 方塊) 傳回 JSON 行錯誤資訊。在此範例中,會將錯誤資訊新增至發生錯誤的annotation物件。

警告錯誤,例如警告無註解,不會用於訓練,並在資訊清單摘要中計為忽略的 JSON 行 (ignored_json_lines)。如需詳細資訊,請參閱了解資訊清單摘要。此外,忽略的 JSON 行不會計入訓練和測試的 20% 錯誤閾值。

如需有關特定非終端資料驗證錯誤的資訊,請參閱非終端 JSON 行驗證錯誤

注意

如果資料驗證錯誤太多,則會停止訓練,並在資訊清單摘要中報告錯誤 _ 無效 _ 列資訊清單終端機錯誤。

如需更正 JSON 行錯誤的詳細資訊,請參閱修正訓練錯誤

JSON 行錯誤格式

Amazon Rekognition 自訂標籤會將非終端機驗證錯誤資訊新增至映像層級和物件本地化格式 JSON 行。如需詳細資訊,請參閱建立清單檔案

影像層級錯誤

下面的例子顯示了在圖像級 JSON 線的Error數組。有兩組錯誤。與標籤屬性中繼資料 (在此範例中為運動中繼資料) 相關的錯誤,以及與影像相關的錯誤。錯誤包括錯誤代碼(代碼),錯誤消息(消息)。如需詳細資訊,請參閱清單檔案中的影像層級標籤

{ "source-ref": String, "sport": Number, "sport-metadata": { "class-name": String, "confidence": Float, "type": String, "job-name": String, "human-annotated": String, "creation-date": String, "errors": [ { "code": String, # error codes for label "message": String # Description and additional contextual details of the error } ] }, "errors": [ { "code": String, # error codes for image "message": String # Description and additional contextual details of the error } ] }

物件本地化錯誤

下面的例子顯示了對象本地化 JSON 行中的錯誤數組。JSON 行包含下列 JSON 行區段中欄位的Errors陣列資訊。每個Error物件都包含錯誤碼和錯誤訊息。

  • 標籤屬性 — 標籤屬性欄位的錯誤。請參閱範例bounding-box中的。

  • 註釋 — 註釋錯誤 (邊界框) 儲存在 label 屬性內的annotations陣列中。

  • 標籤屬性中繼資料 — 標籤屬性中繼資料的錯誤。請參閱範例bounding-box-metadata中的。

  • image — 與標籤屬性、註釋和標籤屬性中繼資料欄位無關的錯誤。

如需詳細資訊,請參閱清單檔案中的物件本地化

{ "source-ref": String, "bounding-box": { "image_size": [ { "width": Int, "height": Int, "depth":Int, } ], "annotations": [ { "class_id": Int, "left": Int, "top": Int, "width": Int, "height": Int, "errors": [ # annotation field errors { "code": String, # annotation field error code "message": String # Description and additional contextual details of the error } ] } ], "errors": [ #label attribute field errors { "code": String, # error code "message": String # Description and additional contextual details of the error } ] }, "bounding-box-metadata": { "objects": [ { "confidence": Float } ], "class-map": { String: String }, "type": String, "human-annotated": String, "creation-date": String, "job-name": String, "errors": [ #metadata field errors { "code": String, # error code "message": String # Description and additional contextual details of the error } ] }, "errors": [ # image errors { "code": String, # error code "message": String # Description and additional contextual details of the error } ] }

JSON 行錯誤示例

下列物件當地語系化 JSON 行 (格式化以供讀取) 顯示錯錯誤 _ 邊界 _ 方塊 _ 太小誤。在此範例中,邊界方框尺寸 (高度和寬度) 不大於 1 x 1。

{ "source-ref": "s3://bucket/Manifests/images/199940-1791.jpg", "bounding-box": { "image_size": [ { "width": 3000, "height": 3000, "depth": 3 } ], "annotations": [ { "class_id": 1, "top": 0, "left": 0, "width": 1, "height": 1, "errors": [ { "code": "ERROR_BOUNDING_BOX_TOO_SMALL", "message": "The height and width of the bounding box is too small." } ] }, { "class_id": 0, "top": 65, "left": 86, "width": 220, "height": 334 } ] }, "bounding-box-metadata": { "objects": [ { "confidence": 1 }, { "confidence": 1 } ], "class-map": { "0": "Echo", "1": "Echo Dot" }, "type": "groundtruth/object-detection", "human-annotated": "yes", "creation-date": "2019-11-20T02:57:28.288286", "job-name": "my job" } }