safe.gis.test.test_interpolate module

class safe.gis.test.test_interpolate.TestInterpolate(methodName='runTest')[source]

Bases: unittest.case.TestCase

test_1d_constant_interpolation_basic()[source]

Interpolation library works for 1D piecewise constant function

test_1d_linear_interpolation_basic()[source]

Interpolation library works for a 1D linear function - basic test

test_constant_interpolation_basic()[source]

Interpolation library works for piecewise constant function

test_interpolation_corner_cases()[source]

Interpolation library returns NaN for incomplete grid points

test_interpolation_random_array_and_nan()[source]

Interpolation library (constant and linear) works with NaN

test_interpolation_raster_data()[source]

Interpolation library works for raster data

This shows interpolation of data arranged with latitudes bottom - up and longitudes left - right

test_linear_interpolation_basic()[source]

Interpolation library works for linear function - basic test

test_linear_interpolation_nan_array()[source]

Interpolation library works (linear mode) with grid points being NaN

test_linear_interpolation_nan_points()[source]

Interpolation library works with interpolation points being NaN

This is was the reason for bug reported in: https://github.com/AIFDR/riab/issues/155

test_linear_interpolation_outside_domain()[source]

Interpolation library sensibly handles values outside the domain

test_linear_interpolation_range()[source]

Interpolation library works for linear function - a range of cases

safe.gis.test.test_interpolate.linear_function(x, y)[source]

Auxiliary function for use with interpolation test