From 949e4d23f16521d5678559ca6248a8dcfaa989bb Mon Sep 17 00:00:00 2001 From: Kamil Monicz Date: Tue, 20 Feb 2024 10:16:51 +0100 Subject: [PATCH] Remove dead code --- api/v1/tile.py | 9 --------- 1 file changed, 9 deletions(-) diff --git a/api/v1/tile.py b/api/v1/tile.py index bc6fd8c..3ed8cfc 100644 --- a/api/v1/tile.py +++ b/api/v1/tile.py @@ -64,15 +64,6 @@ async def get_tile( return Response(content, headers=headers, media_type='application/vnd.mapbox-vector-tile') -def _mvt_rescale(x: float, y: float, x_min: float, y_min: float, x_span: float, y_span: float) -> tuple[int, int]: - x_mvt, y_mvt = MVT_TRANSFORMER.transform(np.array(x), np.array(y)) - - # subtract minimum boundary and scale to MVT extent - x_scaled = np.rint((x_mvt - x_min) / x_span * MVT_EXTENT).astype(int) - y_scaled = np.rint((y_mvt - y_min) / y_span * MVT_EXTENT).astype(int) - return x_scaled, y_scaled - - def _mvt_encode(bbox: BBox, layers: Sequence[dict]) -> bytes: with start_span(description='Transforming MVT geometry'): bbox_coords = np.asarray((get_coordinates(bbox.p1)[0], get_coordinates(bbox.p2)[0]))