CUDAMap
This feature is not supported on the Wolfram Cloud.

CUDAMap[f,lst]
applies f to each element on lst.

DetailsDetails

  • The CUDALink application must be loaded using Needs["CUDALink`"].
  • CUDAMap works only on general vector types such as "Float", "Double", .
  • CUDAMap does not work on fixed vector structure types like "Float[2]", "Integer32[2]", .
  • CUDAMap does not work on symbolic input.
  • CUDAMap is equivalent to Map.
  • The value for f can be either Cos, Sin, Tan, ArcCos, ArcSin, ArcTan, Cosh, Sinh, Exp, Log, Log10, Sqrt, Ceiling, Floor, or Abs.

ExamplesExamplesopen allclose all

Basic Examples  (2)Basic Examples  (2)

First, load the CUDALink application:

In[1]:=
Click for copyable input

This maps the Cos operator on an input list:

In[2]:=
Click for copyable input
Out[2]=

The above is equivalent to Map:

In[3]:=
Click for copyable input
Out[3]=

The input can be CUDAMemory. This loads a list using CUDAMemoryLoad:

In[1]:=
Click for copyable input
Out[1]=

This applies Abs on the input memory:

In[2]:=
Click for copyable input
Out[2]=

The memory returned can be retrieved using CUDAMemoryGet:

In[3]:=
Click for copyable input
Out[3]=
Translate this page: