[问题] gpuArray的值

楼主: k0286 (k0)   2014-10-14 20:33:27
我有一些code想透过gpu跑,
于是去研究了一下PCT box提供的gpu functions
然后写一些测试程式,
发现
data丢到gpuArray跑fft和正常跑fft结果不同
点workspace的变量来看,明明是相同的,但是isrqual却说是不同的
这是什么问题呢?
==以下是我的测试程式
reset(gpuDevice(1));
% c=rand(10);
d=gpuArray(rand(10,1,'double'));
c=gather(d);
isequal(c,d)
e=fft(c);
f=fft(d);
isequal(e,f)
h=gather(f);
isequal(e,h)
作者: sunev (Veritas)   2014-10-14 23:25:00
numerical error ?
楼主: k0286 (k0)   2014-10-15 06:39:00
可是两边都是double运算阿
作者: sunev (Veritas)   2014-10-15 11:05:00
double 运算就不会有numerical error?

Links booklink

Contact Us: admin [ a t ] ucptt.com