Beispiel #1
0
 def test_cell_2_xy_02(self):
     raster = PRaster(infolder + "/small25.tif")
     x = 471927.1
     y = 4116048.5
     row = 43
     col = 71
     cx, cy = raster.cell_2_xy(row, col)
     self.assertEqual((x, y), (cx, cy))
Beispiel #2
0
 def test_cell_2_xy_03(self):
     raster = PRaster(infolder + "/small25.tif")
     xi = self.xi
     yi = self.yi
     rows = self.rows.tolist()
     cols = self.cols.tolist()
     cxi, cyi = raster.cell_2_xy(rows, cols)
     res = (np.array_equal(xi, cxi), np.array_equal(yi, cyi))
     self.assertEqual(res, (True, True))