Skip to content
This repository has been archived by the owner on Aug 16, 2023. It is now read-only.

Running tests fails at test_ocl_interpolate_flow_hires #19

Closed
rcspam opened this issue Oct 14, 2015 · 12 comments
Closed

Running tests fails at test_ocl_interpolate_flow_hires #19

rcspam opened this issue Oct 14, 2015 · 12 comments
Labels

Comments

@rcspam
Copy link

rcspam commented Oct 14, 2015

After a '$ python setup.py test' with nvidia-352 drivers on ubuntu, i have this error:

test_ocl_interpolate_flow_form (tests.test_motion.InterpolateFlowTestCase) ... ok
test_ocl_interpolate_flow_hires (tests.test_motion.InterpolateFlowTestCase) ... OpenCV Error: Gpu API call (CL_MEM_OBJECT_ALLOCATION_FAILURE) in openCLExecuteKernel, file /build/buildd/opencv-2.4.9/modules/ocl/src/cl_operations.cpp, line 413
terminate called after throwing an instance of 'cv::Exception'
  what():  /build/buildd/opencv-2.4.9/modules/ocl/src/cl_operations.cpp:413: error: (-217) CL_MEM_OBJECT_ALLOCATION_FAILURE in function openCLExecuteKernel

Whats's wrong ? Is it a bug ?

Thanx

@rcspam
Copy link
Author

rcspam commented Oct 14, 2015

In the same time, all video files i test with '$ butterflow -r XXX video.mp4' produce a segfault..

@dthpham
Copy link
Owner

dthpham commented Oct 14, 2015

It looks like your hardware isn't capable of completing the 4K resolution tests. What is the output of butterflow -d? What are the dimensions of the files you are testing Butterflow with? Can you run these commands without an error?

# Make a 2 sec 640x480 30fps test video and increase rate to 60fps
ffmpeg -y -f lavfi -i testsrc=duration=2:size=640x480:rate=30:decimals=3 \
-c:v libx264 -crf 18 a.mp4
butterflow -r 2x --poly-s 0.1 a.mp4

@rcspam
Copy link
Author

rcspam commented Oct 14, 2015

$ butterflow -d
OpenCL devices:
  Platform              : NVIDIA CUDA
  Platform Vendor       : NVIDIA Corporation
  Platform Version      : OpenCL 1.2 CUDA 7.5.18
    Device          : GeForce GTX 550 Ti
      Version       : OpenCL 1.1 CUDA
      Version       : 352.41

I have always segfault after ffmpeg reencode and test 'butterflow -r 2x --poly-s 0.1'

@rcspam
Copy link
Author

rcspam commented Oct 14, 2015

For resolutions, segfault at all resolutions !!

@dthpham dthpham changed the title python test error Running tests fails at test_ocl_interpolate_flow_hires Oct 14, 2015
@dthpham
Copy link
Owner

dthpham commented Oct 14, 2015

Your device is not supported. Butterflow only works with OpenCL devices greater than 1.1 with a full device profile. I will add in some code over the weekend that will detect if a device is compatible and issue a warning if it isn't. Thanks.

@dthpham dthpham closed this as completed Oct 14, 2015
@rcspam
Copy link
Author

rcspam commented Oct 14, 2015

Only works with opencl ? No possibility to disable GPU to prefer CPU ?

@dthpham
Copy link
Owner

dthpham commented Oct 14, 2015

Presently, yes. Two core functions in Butterflow depend on having an OpenCL device (although I do have plans on removing this requirement eventually). You can use a CPU, again, as long as it supports OpenCL 1.2 and up but the output of butterflow -d that you posted suggests that you don't have a compatible device.

@rcspam
Copy link
Author

rcspam commented Oct 14, 2015

Understood. Thanks

@dthpham
Copy link
Owner

dthpham commented Oct 15, 2015

No problem. Butterflow will now warn and prevent those with incompatible devices from running the app via bb0c727. Thanks for bringing this to my attention.

@dthpham
Copy link
Owner

dthpham commented Oct 17, 2015

It's now possible to use Butterflow without needing to set up OpenCL. If you're interested in giving this new ability a test drive then checkout the latest master, then make a small test video with ffmpeg -y -f lavfi -i testsrc=duration=0.5:size=640x480:rate=30:decimals=3 -c:v libx264 -crf 18 a.mp4 and run butterflow -sw -r 2x --poly-s 0.1 a.mp4 against it.

But be warned, there's still some bugs associated with the software version of frame interpolation that I'm trying to fix so the accuracy and quality of the frames may be amiss. It's noticeable if you ever try rendering almost anything other than these generated test videos.

Note that with my GPU that video takes .04 minutes to render while it takes 2.14 minutes with the -sw flag. Just something to think about if you're working with anything lengthy 😉.

@rcspam
Copy link
Author

rcspam commented Oct 17, 2015

Great news...
But here, after an install git version from scratch i get a "SegFault error"... :(

@rcspam
Copy link
Author

rcspam commented Oct 17, 2015

Is there a way to sort debug info to show you ?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants