[Perf] Hash videos by source bytes (#49607)

Signed-off-by: Guan-Ming (Wesley) Chiu <105915352+guan404ming@users.noreply.github.com>
Signed-off-by: Guan-Ming Chiu <105915352+guan404ming@users.noreply.github.com>
Co-authored-by: Isotr0py <2037008807@qq.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
This commit is contained in:
Guan-Ming Chiu
2026-07-27 23:57:55 +08:00
committed by GitHub
co-authored by Isotr0py mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
parent d2ca3002d9
commit 04502deca2
8 changed files with 94 additions and 21 deletions
+4 -1
View File
@@ -66,7 +66,10 @@ these are directly passed to the model without HF processing.
"""
VideoItem: TypeAlias = Union[
HfVideoItem, "torch.Tensor", tuple[HfVideoItem, dict[str, Any]]
HfVideoItem,
"torch.Tensor",
tuple[HfVideoItem, dict[str, Any]],
MediaWithBytes[tuple[HfVideoItem, dict[str, Any]]],
]
"""
A `transformers.video_utils.VideoInput` representing a single video item.