Skip to content
Snippets Groups Projects
Commit d6b1a86c authored by Amir MOHAMMADI's avatar Amir MOHAMMADI
Browse files

[VideoToFrames] Fix for VideoAsArray and VideoLikeContainer

parent 1075c8a5
Branches
Tags
1 merge request!110Porting to dask pipelines
......@@ -14,9 +14,11 @@ class VideoToFrames(TransformerMixin, BaseEstimator):
logger.debug(f"{_frmt(self)}.transform")
output = []
for sample in video_samples:
annotations = getattr(sample, "annotations", {})
annotations = getattr(sample, "annotations", {}) or {}
for frame, frame_id in zip(sample.data.data, sample.data.indices):
# video is an instance of VideoAsArray or VideoLikeContainer
video = sample.data
for frame, frame_id in zip(video, video.indices):
new_sample = mario.Sample(
frame,
frame_id=frame_id,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment