[SciPy-User] Parameterizing a curve / Map curve to line

Dharhas Pothina Dharhas.Pothina at twdb.state.tx.us
Wed May 26 08:43:49 EDT 2010


>This is probably overkill, though... you could just use numpy.interp  
>to linearly interpolate your data up by 10-fold or something. (Again,  
>parameterized by t or some index: you just need to resample the x and  
>y data separately and then put it back together... this is what the  
>splprep routines do under the hood.)

Thanks I used this technique with some modifications to get equal spacing and it seems to be working great.

> I would recommend not just testing points for equality, especially  
> after resampling, but for each point, calculate the minimum distance  
> from that point to the boatpath, and if it's below a threshold value,  
> leave it alone.

This was my original plan, I just left it out of the explaination for simplicity.

- dharhas




More information about the SciPy-User mailing list