From cc4c2af750c34289abc2919623837afcc3139d98 Mon Sep 17 00:00:00 2001 From: Marc Date: Thu, 14 May 2020 16:20:43 +0200 Subject: [PATCH] Set should_buffer to True by default in _read_from_stream (#2201) --- torchvision/io/video.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/torchvision/io/video.py b/torchvision/io/video.py index 40d1cfeed85..f0a47d49faf 100644 --- a/torchvision/io/video.py +++ b/torchvision/io/video.py @@ -106,7 +106,7 @@ def _read_from_stream( ) frames = {} - should_buffer = False + should_buffer = True max_buffer_size = 5 if stream.type == "video": # DivX-style packed B-frames can have out-of-order pts (2 frames in a single pkt)