Equivalent to scipy.interpolate.griddata in CUDA

I am trying to do Set Value Iteration (FVI) in python (using approximation of a 5 dimensional function using piecewise linear interpolation).

scipy.interpolate.griddata works great for this. However, I need to call the interpolation procedure several thousand times (since FVI is an MC based algorithm).

Thus, the set of points at which the function is known is static (and large - say 32k), but the points I need to approximate (which are small perturbations of the original set) are very large (32k x 5000 say).

Is there an implementation that scipy.interpolate.griddata does porting in CUDA? alternatively, is there a way to speed up the calculation in some way?

Thanks.

+6
source share
1 answer

For piecewise linear interpolation, documents say that scipy.interpolate.griddata uses scipy.interpolate.griddata methods, which in turn uses qhull to make an accurate estimate of the Delaunay input points, then performs standard barycentric interpolation, where for each point you must define each point within each hypertetrahedron, then use its barycentric coordinates as the interpolation weights for the value of the node hypertetrahedron.

It may be difficult to redistribute sorting, but you can access the CPU version from scipy.spatial.Delaunay . The remaining two steps are easily parallelized, although I do not know about a freely available implementation.

If your points with known functions are on a regular grid, the method described here is very simple to implement in CUDA, and I worked with its actual implementations, although not publicly available.

Therefore, I am afraid that you will have to do most of the work yourself ...

+1
source

All Articles