例如,針對平交道上的火車影片,Video Intelligence API 可能傳回「火車」、「運輸」、「鐵路平交道」等的標籤。每個標籤的時間片段均含有時間偏移 (時間戳記),指出出現的實體距離影片開始的時間距離。每個註解還含有其他資訊,包括您在 Google Knowledge Graph Search API 中用來搜尋實體更多相關資訊的實體 ID。
每個傳回的實體也會在 categoryEntities 欄位中提供相關聯的類別實體。例如,「㹴犬」實體標籤的類別為「狗」。類別實體具有階層結構。例如,「狗」類別是階層中「哺乳動物」類別的子項。如需 Video Intelligence 所使用的一般類別實體清單,請參閱 entry-level-categories.json。
[[["容易理解","easyToUnderstand","thumb-up"],["確實解決了我的問題","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["難以理解","hardToUnderstand","thumb-down"],["資訊或程式碼範例有誤","incorrectInformationOrSampleCode","thumb-down"],["缺少我需要的資訊/範例","missingTheInformationSamplesINeed","thumb-down"],["翻譯問題","translationIssue","thumb-down"],["其他","otherDown","thumb-down"]],["上次更新時間:2025-09-04 (世界標準時間)。"],[],[],null,["# Analyze videos for labels\n\nThe Video Intelligence API can identify entities shown in video footage\nusing the [LABEL_DETECTION](/video-intelligence/docs/reference/rest/v1/videos/annotate#feature)\nfeature and annotate these entities with labels (tags). This feature identifies\nobjects, locations, activities, animal species, products, and more.\n\nLabel detection differs from [Object tracking](/video-intelligence/docs/object-tracking).\nUnlike object tracking, label detection provides labels for the entire frame\n(without bounding boxes).\n\nFor example, for a video of a train at a crossing, the Video Intelligence API\nreturns labels such as \"train\", \"transportation\", \"railroad crossing\",\nand so on. Each label includes a time segment with the time offset (timestamp)\nfor the entity's appearance from the beginning of the video.\nEach annotation also contains additional information including an entity\nid that you can use to find more information about the\nentity in the [Google Knowledge Graph Search API](https://developers.google.com/knowledge-graph/).\n\nEach entity returned can also include associated\ncategory entities in the `categoryEntities` field. For example the\n\"Terrier\" entity label has a category of \"Dog\". Category entities have a\nhierarchy. For example, the \"Dog\" category is a child of the \"Mammal\"\ncategory in the hierarchy. For a list of the common category entities that the\nVideo Intelligence uses, see\n[entry-level-categories.json](/static/video-intelligence/docs/entry-level-categories.json).\n\nThe analysis can be compartmentalized as follows:\n\n- Segment level: \n User-selected segments of a video can be specified for analysis by stipulating beginning and ending timestamps for the purposes of annotation (see [VideoSegment](/video-intelligence/docs/reference/rest/v1/videos/annotate#videosegment)). Entities are then identified and labeled within each segment. If no segments are specified, the whole video is treated as one segment.\n\n \u003cbr /\u003e\n\n \u003cbr /\u003e\n\n- Shot level: \n Shots (also known as a *scene* ) are automatically detected within every segment (or video). Entities are then identified and labeled within each scene. For details, see [Shot change detection](#shot-change)\n- Frame level: \n Entities are identified and labeled within each frame (with one frame per second sampling).\n\n\u003cbr /\u003e\n\nTo detect labels in a video, call the\n[`annotate`](/video-intelligence/docs/reference/rest/v1/videos/annotate)\nmethod and specify\n[`LABEL_DETECTION`](/video-intelligence/docs/reference/rest/v1/videos#Feature)\nin the `features` field.\n\nSee\n[Analyzing Videos for Labels](/video-intelligence/docs/analyze-labels) and\n[Label Detection Tutorial](/video-intelligence/docs/label-tutorial).\n\nVideo Intelligence API Visualizer\n=================================\n\nCheck out the [Video Intelligence API visualizer](https://zackakil.github.io/video-intelligence-api-visualiser/#Label%20Detection) to see this feature in action."]]