torch / torch7

http://torch.ch
Other
8.97k stars 2.38k forks source link

Compilation Error: Cuda 9? #1109

Open bnsh opened 6 years ago

bnsh commented 6 years ago

Hi. I was following the instructions at http://torch.ch/docs/getting-started.html#_ for building torch.. It seems to have cuda 9 (It's a dgx-station)...

I'm getting this error now tho: (Many instances of it, but, they all seem to be about the same kind of error)

/usr/local/src/torch/extra/cutorch/lib/THC/generic/THCTensorMathPairwise.cu(66): error: more than one operator "!=" matches these operands: function "operator!=(const __half &, const __half &)" function "operator!=(half, half)" operand types are: half != half

Has anyone else seen this?

sabpap commented 6 years ago

Same issue here: https://github.com/torch/cutorch/issues/797

eazolan commented 6 years ago

Before you build try

export TORCH_NVCC_FLAGS="-D__CUDA_NO_HALF_OPERATORS__"

It worked for me. I got it from this thread:

https://github.com/torch/cutorch/issues/797