Skip to content
This repository has been archived by the owner on Feb 22, 2020. It is now read-only.

Commit

Permalink
fix(preprocessor): fix bug in ffmpeg
Browse files Browse the repository at this point in the history
  • Loading branch information
Larryjianfeng committed Aug 1, 2019
1 parent 67610f8 commit f8d2abe
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gnes/preprocessor/video/ffmpeg.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ def __init__(self,
def apply(self, doc: 'gnes_pb2.Document') -> None:
super().apply(doc)
if doc.raw_bytes:
frames = get_video_frames(doc.raw_bytes, **kwargs)
frames = get_video_frames(doc.raw_bytes, **self._ffmpeg_kwargs)

sub_videos = []
if len(frames) >= 1:
Expand All @@ -143,7 +143,7 @@ def apply(self, doc: 'gnes_pb2.Document') -> None:
else:
sub_videos = [frames]

for ci, c hunk in enumerate(sub_videos):
for ci, chunk in enumerate(sub_videos):
c = doc.chunks.add()
c.doc_id = doc.doc_id
c.blob.CopyFrom(array2blob(np.array(chunk, dtype=np.uint8)))
Expand Down

0 comments on commit f8d2abe

Please sign in to comment.