The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.matlab

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: feval works but gather fails
Replies: 1   Last Post: Feb 18, 2013 4:14 AM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View  
Edric Ellis

Posts: 721
Registered: 12/7/04
Re: feval works but gather fails
Posted: Feb 18, 2013 4:14 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

"AL_math " <> writes:

> I am processing an image, by using CUDA kernels. I am calling
> GPUoutput = feval(........ ), and everything is fine, no error
> messages appear. But when I call: "output = gather(GPUoutput);" then
> I get an error messagse:
> " Error using parallel.gpu.GPUArray/gather
> An unexpected error occurred during CUDA execution. The CUDA error was:

All CUDA kernel invocations return before the actual computation is
complete, so problems in your kernel can show up later when you try and
access the resulting data. I suspect that is what is happening here.

> The more strange fact, is that when I am calling less blocks of
> threads to process only part of the image, but still need to gather
> back an image of the same size (which is simply partially black) the
> problem is gone.

It sounds like when you try to work on the whole image, you may be
reading or writing beyond the bounds of the image.



Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2018. All Rights Reserved.