yjxiong / temporal-segment-networks

Code & Models for Temporal Segment Networks (TSN) in ECCV 2016
BSD 2-Clause "Simplified" License
1.53k stars 477 forks source link

extract_optical_flow using docker image #266

Open tobiascz opened 5 years ago

tobiascz commented 5 years ago

when I use the provided docker image to extract the optical_flow images using extract_optical_flow.sh the images are not created.

The OUT_FOLDER gets filled with empty folders matching the structure of the SRC_FOLDER but there are no images in the folders.

in local/errors.log I get the following error messages:

OpenCV Error: Gpu API call (no kernel image is available for execution on the device) in call, file /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp, line 361
terminate called after throwing an instance of 'cv::Exception'
  what():  /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp:361: error: (-217) no kernel image is available for execution on the device in function call

Aborted (core dumped)
OpenCV Error: Gpu API call (no kernel image is available for execution on the device) in call, file /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp, line 361
terminate called after throwing an instance of 'cv::Exception'
  what():  /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp:361: error: (-217) no kernel image is available for execution on the device in function call

Aborted (core dumped)
OpenCV Error: Gpu API call (no kernel image is available for execution on the device) in call, file /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp, line 361
terminate called after throwing an instance of 'cv::Exception'
  what():  /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp:361: error: (-217) no kernel image is available for execution on the device in function call

Any ideas?

username123062 commented 5 years ago

I have the same problem with you.

ymxv commented 5 years ago

when I use the provided docker image to extract the optical_flow images using extract_optical_flow.sh the images are not created.

The OUT_FOLDER gets filled with empty folders matching the structure of the SRC_FOLDER but there are no images in the folders.

in local/errors.log I get the following error messages:

OpenCV Error: Gpu API call (no kernel image is available for execution on the device) in call, file /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp, line 361
terminate called after throwing an instance of 'cv::Exception'
  what():  /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp:361: error: (-217) no kernel image is available for execution on the device in function call

Aborted (core dumped)
OpenCV Error: Gpu API call (no kernel image is available for execution on the device) in call, file /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp, line 361
terminate called after throwing an instance of 'cv::Exception'
  what():  /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp:361: error: (-217) no kernel image is available for execution on the device in function call

Aborted (core dumped)
OpenCV Error: Gpu API call (no kernel image is available for execution on the device) in call, file /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp, line 361
terminate called after throwing an instance of 'cv::Exception'
  what():  /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp:361: error: (-217) no kernel image is available for execution on the device in function call

Any ideas?

if you run image with command docker run --runtime=nvidia -ti bitxiong/tsn bash ? Maybe you didn't start the GPU

tx1994108 commented 5 years ago

I have the same problem.Does anyone know how to solve it?

yjxiong commented 5 years ago

To run optical flow extraction you need the CUDA runtime and a NVIDIA GPU for the Docker. For the latest versions of Docker, you can use the nvidia-docker run command.

niveditarahurkar commented 5 years ago

hi,

I see an invalid device error:

OpenCV Error: Gpu API call (invalid device ordinal) in setDevice, file /app/3rd-party/opencv-2.4.13/modules/dynamicuda/include/opencv2/dynamicuda/dynamicuda.hpp, line 658 terminate called after throwing an instance of 'cv::Exception' what(): /app/3rd-party/opencv-2.4.13/modules/dynamicuda/include/opencv2/dynamicuda/dynamicuda.hpp:658: error: (-217) invalid device ordinal in function setDevice

Aborted (core dumped)

@tobiascz did your issue get fixed? @yjxiong I am using the docker image that you provided. Running it on GCE with GPU instance.

I have this system :

root@a6af5209b53a:/app/ucfdata# uname -r
4.9.0-9-amd64

root@a6af5209b53a:/app/ucfdata# cat /etc/os-release
NAME="Ubuntu"
VERSION="16.04.4 LTS (Xenial Xerus)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 16.04.4 LTS"
VERSION_ID="16.04"
HOME_URL="http://www.ubuntu.com/"
SUPPORT_URL="http://help.ubuntu.com/"
BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/"
VERSION_CODENAME=xenial
UBUNTU_CODENAME=xenial
root@a6af5209b53a:/app/ucfdata#

So Is this the correct cuda I am installing?-- sudo dpkg -i cuda-repo-ubuntu1404-10-1-local-10.1.168-418.67_1.0-1_amd64.deb sudo apt-key add /var/cuda-repo-<version>/7fa2af80.pub sudo apt-get update sudo apt-get install cuda

I am getting an error during cuda install-

Errors were encountered while processing:
 nvidia-418
 nvidia-418-dev
 libcuda1-418
 nvidia-opencl-icd-418
 cuda-drivers
 cuda-runtime-10-1
 cuda-demo-suite-10-1
 cuda-10-1
 cuda
E: Sub-process /usr/bin/dpkg returned an error code (1)

Does anyone know how to fix this?

nanhui69 commented 4 years ago

@yjxiong when i did it with bash scripts/extract_optical_flow.sh ucf-101/ApplyEyeMakeup/ ,it occurs that bash scripts/extract_optical_flow.sh UCF-101/ApplyEyeMakeup/ frame_result/ApplyEyeMakeup/ 2 Extracting optical flow from videos in folder: UCF-101/ApplyEyeMakeup/ ('reading videos from folder: ', 'UCF-101/ApplyEyeMakeup/') ('selected extension of videos:', 'avi') ('total number of videos found: ', 145) 2019-09-11 16:51:24,712 FATAL [default] CRASH HANDLED; Application has crashed due to [SIGSEGV] signal 2019-09-11 16:51:24,712 FATAL [default] CRASH HANDLED; Application has crashed due to [SIGSEGV] signal 2019-09-11 16:51:24,713 WARN [default] Aborting application. Reason: Fatal log at [/home/wangnanhui/algorith_proj/temporal-segment-networks/lib/dense_flow/include/easylogging++/src/easylogging++.h:5583] it is so amazing ,so How to do this? my configuration is centos7 opencv2.4.13 python2.7 nvidia9.1 .

Wnaner commented 4 years ago

@yjxiong when i did it with bash scripts/extract_optical_flow.sh ucf-101/ApplyEyeMakeup/ ,it occurs that bash scripts/extract_optical_flow.sh UCF-101/ApplyEyeMakeup/ frame_result/ApplyEyeMakeup/ 2 Extracting optical flow from videos in folder: UCF-101/ApplyEyeMakeup/ ('reading videos from folder: ', 'UCF-101/ApplyEyeMakeup/') ('selected extension of videos:', 'avi') ('total number of videos found: ', 145) 2019-09-11 16:51:24,712 FATAL [default] CRASH HANDLED; Application has crashed due to [SIGSEGV] signal 2019-09-11 16:51:24,712 FATAL [default] CRASH HANDLED; Application has crashed due to [SIGSEGV] signal 2019-09-11 16:51:24,713 WARN [default] Aborting application. Reason: Fatal log at [/home/wangnanhui/algorith_proj/temporal-segment-networks/lib/dense_flow/include/easylogging++/src/easylogging++.h:5583] it is so amazing ,so How to do this? my configuration is centos7 opencv2.4.13 python2.7 nvidia9.1 . Do you solve the problem?

Wnaner commented 4 years ago

2019-09-11 16:51:24,712 FATAL [default] CRASH HANDLED; Application has crashed due to [SIGSEGV] signal 2019-09-11 16:51:24,713 WARN [default] Aborting application. Reason: Fatal log at [/home/wangnanhui/algorith_proj/temporal-segment-networks/lib/dense_flow/include/easylogging++/src/easylogging++.h:5583]

Hi, I think mostly this problem is due to the wrong dir or folder . For me, I cannot mkdir in the disk where I put the video folder and frame folder . So I guess the problem happend because the frame folder can't be build or the dir can't be built. I solved it by remove some files.

WangShuu commented 3 years ago

when I use the provided docker image to extract the optical_flow images using extract_optical_flow.sh the images are not created.

The OUT_FOLDER gets filled with empty folders matching the structure of the SRC_FOLDER but there are no images in the folders.

in local/errors.log I get the following error messages:

OpenCV Error: Gpu API call (no kernel image is available for execution on the device) in call, file /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp, line 361
terminate called after throwing an instance of 'cv::Exception'
  what():  /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp:361: error: (-217) no kernel image is available for execution on the device in function call

Aborted (core dumped)
OpenCV Error: Gpu API call (no kernel image is available for execution on the device) in call, file /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp, line 361
terminate called after throwing an instance of 'cv::Exception'
  what():  /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp:361: error: (-217) no kernel image is available for execution on the device in function call

Aborted (core dumped)
OpenCV Error: Gpu API call (no kernel image is available for execution on the device) in call, file /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp, line 361
terminate called after throwing an instance of 'cv::Exception'
  what():  /app/3rd-party/opencv-2.4.13/modules/gpu/include/opencv2/gpu/device/detail/transform_detail.hpp:361: error: (-217) no kernel image is available for execution on the device in function call

Any ideas?

Have you solved this problem?I just met the same problem as you.