You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
VideoReader segmentation fault on long videos when using video_reader backend.
Notes:
doesn't seem to happen with pyav backend
reading in the entire video, without timestams seems to hang - not sure if this is the function of the video being to long or internal errors
To Reproduce
Steps to reproduce the behavior:
select a video (in this case EPIC Kitchens videos
set the tv.video_backend to video_reader
read a video longer than (in my experience with 24 and 30fps videos) 15s
observe segfault
Example of an ipython testing:
# works with pyav
In [1]: import torchvision as tv
In [2]: video_path = "/EPIC_KITCHENS_2018/062519/videos_24fps/train/P08/P08_21.MP4"
In [3]: video = tv.io.read_video(video_path, 0, 15.5, pts_unit="sec")
# success
# now set a video_reader background to try the same command?
In [4]: tv.set_video_backend("video_reader")
In [5]: video = tv.io.read_video(video_path, 0.5, 15.5, pts_unit="sec")
[F VideoReader.cpp:326] Check failed: numberWrittenBytes == expectedWrittenBytes (2245708800 vs. 18446744071660293120)
[1] 8565 abort (core dumped) ipython
Expected behavior
Video is successfully read and returned as a tensor object
Environment
PyTorch version: 1.6.0.dev20200522
Is debug build: No
CUDA used to build PyTorch: 10.1
Python version: 3.7
Is CUDA available: Yes
CUDA runtime version: Could not collect
GPU models and configuration:
GPU 0: Quadro GP100
GPU 1: Quadro GP100
Nvidia driver version: 418.116.00
cuDNN version: Could not collect
So far I had it segfault on 3 different datasets, all of which inclueded loading longer video, although I can't find the culprit yet (It's not always the length, so I suspect it has to do something with memory it has to allocate for the decoding, but not sure).
Also, as I sidenote, this happened after I updated TV from 0.5a to 0.7. On 0.5 the same dataset seemed to work (but there is some length randomization, so that's not 100% reliable information.
🐛 Bug
VideoReader segmentation fault on long videos when using
video_reader
backend.Notes:
To Reproduce
Steps to reproduce the behavior:
tv.video_backend
tovideo_reader
Example of an ipython testing:
Expected behavior
Video is successfully read and returned as a tensor object
Environment
PyTorch version: 1.6.0.dev20200522
Is debug build: No
CUDA used to build PyTorch: 10.1
OS: Ubuntu 18.04.3 LTS
GCC version: (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0
CMake version: version 3.10.2
Python version: 3.7
Is CUDA available: Yes
CUDA runtime version: Could not collect
GPU models and configuration:
GPU 0: Quadro GP100
GPU 1: Quadro GP100
Nvidia driver version: 418.116.00
cuDNN version: Could not collect
Versions of relevant libraries:
[pip] numpy==1.18.1
[pip] torch==1.6.0.dev20200522
[pip] torchvision==0.7.0a0+3d65fc6
[conda] blas 1.0 mkl
[conda] cudatoolkit 10.1.243 h6bb024c_0
[conda] mkl 2020.0 166
[conda] mkl-service 2.3.0 py37he904b0f_0
[conda] mkl_fft 1.0.15 py37ha843d7b_0
[conda] mkl_random 1.1.0 py37hd6b4f25_0
[conda] numpy 1.18.1 py37h4f9e942_0
[conda] numpy-base 1.18.1 py37hde5b4d6_1
[conda] pytorch 1.6.0.dev20200522 py3.7_cuda10.1.243_cudnn7.6.3_0 pytorch-nightly
[conda] torchvision 0.7.0a0+3d65fc6 pypi_0 pypi
conda
/ source):python setup.py install
The text was updated successfully, but these errors were encountered: