[SciPy-User] LinearNDInterpolator hanging

Pauli Virtanen pav at iki.fi
Sat Mar 26 10:30:10 EDT 2011


On Sat, 26 Mar 2011 23:30:32 +1100, Wolfgang Kerzendorf wrote:
> With some of my grids, the LinearNDInterpolator is crashing. Well it
> just hangs and still uses CPU. 

Probably same problem as

	http://projects.scipy.org/scipy/ticket/1412

I'm looking into it. The problem seems to be that if there are very thin 
sliver triangles in the triangulation, they can cause rounding errors in 
the barycentric transforms in the triangle walking algorithm and make it 
think two triangles are both closer to the target point.

This can be solved by limiting the iteration count, and falling back to 
brute force if it fails. I'll make that change.

> Ah I sort the points, before I give them to the grid.

That's needed for the 1-D problem only.

-- 
Pauli Virtanen




More information about the SciPy-User mailing list