If data is integer then interpolation might fail. Interpolation has to be done in float and converted back to int.