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

OverflowError: size does not fit in an int #28

Open
shecker opened this issue Feb 21, 2019 · 4 comments
Open

OverflowError: size does not fit in an int #28

shecker opened this issue Feb 21, 2019 · 4 comments

Comments

@shecker
Copy link

shecker commented Feb 21, 2019

Hi Brendan, thanks for this awesome library.
I have noticed that I am unable to load videos greater than a certain size using this library. For example I am working with videos around 4GB in size and when I try to load those in via

import lintel
with open( 'a_4GB_video.MP4', 'rb') as f:
    video = f.read()
    decoded_frames, width, height = lintel.loadvid_frame_nums( video, frame_nums=2)

I get:

OverflowError: size does not fit in an int.

Could this be due to some 32bit code? I am able to use this library with smaller videos (~200mb works fine)
Thanks a lot.
Cheers,
Simon

@dukebw
Copy link
Owner

dukebw commented Feb 21, 2019

Hi Simon,

Interesting, I am a bit puzzled about the Python OverflowError exception here. I will take a look at reproducing tonight.

@dukebw
Copy link
Owner

dukebw commented Feb 22, 2019

Would it be possible to give the big-videos branch a try, please? I made a couple small changes to pass sizes as size_t instead of int.

@shecker
Copy link
Author

shecker commented Feb 27, 2019

Hi Brendan,
Sorry for the late reply. I gave your big-videos branch a go but still no luck.
I get the following error:

AVERROR: -1094995529, message: Invalid data found when processing input
Stream index not found.
python: lintel/py_ext/lintelmodule.c:244: get_vid_width_height: Assertion `((uint32_t)codec_context->width == *width) && ((uint32_t)codec_context->height == *height)' failed.
Aborted

However, I have adjusted to smaller video chunks of around 1GB which may be more suitable anyway. Therefore will just stick to the master branch that works great on those videos.
Thanks a lot for your help.
Cheers,
Simon

EDIT: if you are interested I have made a 4GB file available to test. It's captured via a GoPro Hero5 and contains some meta tracks embedded within the mp4 container as well. This might also be the cause for the error. You can find it here http://people.ee.ethz.ch/~heckers/Drive360/meta_debug/GP030100.MP4 and just download via wget

@dukebw
Copy link
Owner

dukebw commented Feb 27, 2019

Hi Simon,

That is great, I'm glad that you found a solution anyway. And thank you for uploading the video -- I will leave this issue open and debug further once I have time.

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

2 participants