提交 62b3bbdb authored 作者: Frédéric Bastien's avatar Frédéric Bastien

Merge pull request #3241 from abergeron/nan_gpu

Add definition of NAN to cuda_ndarray.cuh.
...@@ -42,6 +42,13 @@ ...@@ -42,6 +42,13 @@
#define SIZE_MAX ((size_t)-1) #define SIZE_MAX ((size_t)-1)
#endif #endif
// Cuda GPUs only accept a single representation for NaN whereas CPU may have
// more than one. So it's better to use the CUDA one to be sure
#ifdef NAN
#undef NAN
#endif
#include <math_constants.h>
#define NAN CUDART_NAN_F
#include <cublas_v2.h> #include <cublas_v2.h>
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论