我在一台配备 TESLA C2075 的机器上安装了 pycuda。我在安装了 CUDA-6.0 编译器的 Ubuntu 14.04 上运行。
使用 python 2.7.9(通过 anaconda 发行版)和 numpy 1.9.0,我从 Andreas Kloeckner 在他的网站上提供的 ZIP 文件中安装了 pycuda 2014.1。(http://mathema.tician.de/software/pycuda/)
运行该 ZIP 文件提供的测试一切顺利,除了该test_cumath.py
文件。我收到以下错误:
E AssertionError: (2.3841858e-06, 'cosh', <type 'numpy.complex64'>)`
E assert <built-in method all of numpy.bool_ object at 0x7f00747f3880>()`
E + where <built-in method all of numpy.bool_ object at 0x7f00747f3880> = 2.3841858e-06 <= 2e-06.all
test_cumath.py:54: AssertionError`
===== 1 failed, 27 passed in 12.57 seconds =====
有没有人建议cosh的GPU和CPU结果之间的这种差异来自哪里?测量值 2.38e-6 略高于 2e-6 的容差,这对我来说有点奇怪。尤其是其他的测试都成功了……?