def __init__(self, level):
     self.level = level
     self.cnt_x = (180*2)//step_from_level(level) + 1
     lst_coord = make_tuple_coord(level)
     self.expected = dict(
         cnt=len(lst_coord),
         lst_coord=set(lst_coord)
     )
     self.actual = dict(cnt=0, lst_coord=list())
Ejemplo n.º 2
0
 def __init__(self, level, x_min, y_min, x_max, y_max):
     super().__init__(level)
     step = step_from_level(level)
     step = 1
     x_min, y_min, x_max, y_max = map(
         lambda x: int(x) + (0 if int(x) > x else 1),
         [x_min, y_min, x_max, y_max])
     lst_coord = [(lon, lat) for lon in range(x_min, x_max, step)
                  for lat in range(y_min, y_max, step)]
     self.expected = dict(cnt=len(lst_coord), lst_coord=set(lst_coord))
Ejemplo n.º 3
0
def make_coord(level):
    step = step_from_level(level)
    return list(iter_lon_lat(step))