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

CUDA error 8: invalid device function #1313

Open
RdlP opened this issue Oct 10, 2017 · 5 comments
Open

CUDA error 8: invalid device function #1313

RdlP opened this issue Oct 10, 2017 · 5 comments

Comments

@RdlP
Copy link

RdlP commented Oct 10, 2017

I am using dockers from: https://hub.docker.com/r/caffe2ai/caffe2/

I have a custom network model in caffe2 (written by me), and it works perfectly in CPU. Now I am trying to run it over GPU. In order to do that I defined device_opts as follow

device_opts = caffe2_pb2.DeviceOption()
device_opts.device_type = caffe2_pb2.CUDA
device_opts.cuda_gpu_id = 0

and pass it to the blobs

workspace.FeedBlob("x_train", x_train, device_opts)
workspace.FeedBlob("y_train", y_train, device_opts)

finally to predict I use RunNet function instead of Predictor interface (because I read that it doesn't work with GPU)

workspace.RunNet(model.net)

When I run the code I get many cuda errors

CUDA error 8 [/caffe2/third_party/cub/cub/block/../iterator/../util_device.cuh, 151]: invalid device function
CUDA error 8 [/caffe2/third_party/cub/cub/device/dispatch/dispatch_reduce.cuh, 697]: invalid device function
CUDA error 8 [/caffe2/third_party/cub/cub/block/../iterator/../util_device.cuh, 151]: invalid device function
CUDA error 8 [/caffe2/third_party/cub/cub/device/dispatch/dispatch_reduce.cuh, 697]: invalid device function

Anybody knows about these errors?

@Yangqing
Copy link
Contributor

@slayton58 @lukeyeager do you guys have a guess? :) This looks a bit new to me...

@slayton58
Copy link
Contributor

Could be compiled for the wrong GPU architecture(s), but I don't have enough details to say for sure.

@pietern
Copy link
Contributor

pietern commented Oct 11, 2017

@RdlP What kind of GPU are you trying to run this on?

@slayton58 I think I've seen this as well when the CUDA ARCHs didn't match the GPU arch.

@RdlP
Copy link
Author

RdlP commented Oct 11, 2017

@pietern I am trying to run on GeForce GTX 750 Ti with 2GB

@slayton58
Copy link
Contributor

That's a Maxwell card, so it should normally be covered - @Yangqing @pietern what architectures does the docker build use? My reading of what I can find suggests sm50 and 52 should be covered...

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

No branches or pull requests

4 participants