DataverseLabs / pyinterpolate

Kriging | Poisson Kriging | Variogram Analysis
https://pyinterpolate.readthedocs.io/en/stable/
BSD 3-Clause "New" or "Revised" License
151 stars 26 forks source link

[BUG] Protect `interpolate_raster` from Singular Matrix error #412

Closed SimonMolinsky closed 1 year ago

SimonMolinsky commented 1 year ago

Package version 0.5.0.post1

Describe the bug There is a chance that the process will generate canvas points with the same coordinates as weighting points, leading to a Singular Matrix error.

Expected behavior Don't pass all canvas points to the kriging process. Filter those with the same coordinates as known observations and immediately assign real values to them. The kriging error is equal to 0.