Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Having issues with VideoReader for certain videos (cannot create buffer source) #295

Open
trudramukerji14 opened this issue Mar 22, 2024 · 0 comments

Comments

@trudramukerji14
Copy link

trudramukerji14 commented Mar 22, 2024

Thanks for the awesome package.

I'm having issues with the VideoReader function. Namely, I downloaded the following using yt-dlp: YouTube video which was saved as an mp4 video path attached below. I then tried the following code.

videopath = 'data/jJzILuaFu-0.mp4_trimmed.mp4' vr = VideoReader(videopath)

But got the following error below. I was wondering if I could get some advice on what to do here.

Uploading jJzILuaFu-0.mp4_trimmed.mp4…

`DECORDError Traceback (most recent call last)
in <cell line: 3>()
1 videopath = 'data/jJzILuaFu-0.mp4_trimmed.mp4'
2
----> 3 vr = VideoReader(videopath)

/usr/local/lib/python3.10/dist-packages/decord/video_reader.py in init(self, uri, ctx, width, height, num_threads, fault_tol)
52 ba, ctx.device_type, ctx.device_id, width, height, num_threads, 2, fault_tol)
53 else:
---> 54 self._handle = _CAPI_VideoReaderGetVideoReader(
55 uri, ctx.device_type, ctx.device_id, width, height, num_threads, 0, fault_tol)
56 if self._handle is None:

/usr/local/lib/python3.10/dist-packages/decord/_ffi/_ctypes/function.py in call(self, *args)
171 ret_val = DECORDValue()
172 ret_tcode = ctypes.c_int()
--> 173 check_call(_LIB.DECORDFuncCall(
174 self.handle, values, tcodes, ctypes.c_int(num_args),
175 ctypes.byref(ret_val), ctypes.byref(ret_tcode)))
78 raise DECORDError(err_str)
79
80

DECORDError: [15:02:47] /github/workspace/src/video/ffmpeg/filter_graph.cc:61: Check failed: avfilter_graph_create_filter(&buffersrc_ctx_, buffersrc, "in", args, _null, filter_graph.get()) >= 0 (-22 vs. 0) Cannot create buffer source`

jJzILuaFu-0.mp4_trimmed.mp4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant