def check_1pixshift_i(self): test_copy1 = self.test_sig_rand_i.copy() test_copy2 = test_copy1.copy() FTS.subsampInterp(test_copy1, 1.0, axis=0) util.shift(test_copy2, 1, axis=0) assert_array_almost_equal(test_copy2[1:-1,:,:], test_copy1[1:-1,:,:], decimal=5)
def run(self, image): if self.xshift: shift(image[:], self.xshift, axis=-1) if self.yshift: shift(image[:], self.yshift, axis=-2)