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

why CudaTensor? #14

Open
foice opened this issue Mar 21, 2016 · 2 comments
Open

why CudaTensor? #14

foice opened this issue Mar 21, 2016 · 2 comments

Comments

@foice
Copy link

foice commented Mar 21, 2016

Hi, I am very excited to try word-rnn and I have installed torch and all that on OS X 10.11

Running the test program th train.lua -gpuid -1 I get an error connected to Cuda, which is

./util/SharedDropout.lua:3: attempt to call field 'CudaTensor' (a nil value)

Is this how it is supposed to be? any ideas for this error?

Thanks,
Roberto

PS
Please note I have a (old) GPU, some CUDA installed in my system (6.0), but wanted torch to work on CPU only, so I have "cheated" in the installation of torch and avoided it to find nvcc, so I am a bit surprised the code uses "CudaTensor" ...

@psychosomaticdragon
Copy link

If you modify torch.CudaTensor() to torch.Tensor() in /util/SharedDropout.lua it works fine on the cpu. Probably should be changed to behave correctly though (opencl mode using cltensor, cpu mode using tensor)

@foice
Copy link
Author

foice commented Apr 1, 2016

Well, it worked! thanks for the tip!

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