|
20 | 20 | # SPDX-License-Identifier: MIT
|
21 | 21 | # ******************************************************************************
|
22 | 22 |
|
23 |
| -from __future__ import division |
24 |
| - |
25 | 23 | import contextlib
|
26 | 24 | import glob
|
27 | 25 | import json
|
@@ -129,7 +127,7 @@ class UnsupportedTileMatrixSet(Exception):
|
129 | 127 | pass
|
130 | 128 |
|
131 | 129 |
|
132 |
| -class TileMatrixSet(object): |
| 130 | +class TileMatrixSet: |
133 | 131 | def __init__(self) -> None:
|
134 | 132 | self.identifier = None
|
135 | 133 | self.srs = None
|
@@ -328,7 +326,7 @@ def get_profile_list():
|
328 | 326 | MAXZOOMLEVEL = 32
|
329 | 327 |
|
330 | 328 |
|
331 |
| -class GlobalMercator(object): |
| 329 | +class GlobalMercator: |
332 | 330 | r"""
|
333 | 331 | TMS Global Mercator Profile
|
334 | 332 | ---------------------------
|
@@ -547,7 +545,7 @@ def QuadTree(self, tx, ty, zoom):
|
547 | 545 | return quadKey
|
548 | 546 |
|
549 | 547 |
|
550 |
| -class GlobalGeodetic(object): |
| 548 | +class GlobalGeodetic: |
551 | 549 | r"""
|
552 | 550 | TMS Global Geodetic Profile
|
553 | 551 | ---------------------------
|
@@ -644,7 +642,7 @@ def TileLatLonBounds(self, tx, ty, zoom):
|
644 | 642 | return (b[1], b[0], b[3], b[2])
|
645 | 643 |
|
646 | 644 |
|
647 |
| -class Zoomify(object): |
| 645 | +class Zoomify: |
648 | 646 | """
|
649 | 647 | Tiles compatible with the Zoomify viewer
|
650 | 648 | ----------------------------------------
|
@@ -2126,7 +2124,7 @@ def options_post_processing(
|
2126 | 2124 | return options
|
2127 | 2125 |
|
2128 | 2126 |
|
2129 |
| -class TileDetail(object): |
| 2127 | +class TileDetail: |
2130 | 2128 | tx = 0
|
2131 | 2129 | ty = 0
|
2132 | 2130 | tz = 0
|
@@ -2155,7 +2153,7 @@ def __repr__(self):
|
2155 | 2153 | return "TileDetail %s\n%s\n%s\n" % (self.tx, self.ty, self.tz)
|
2156 | 2154 |
|
2157 | 2155 |
|
2158 |
| -class TileJobInfo(object): |
| 2156 | +class TileJobInfo: |
2159 | 2157 | """
|
2160 | 2158 | Plain object to hold tile job configuration for a dataset
|
2161 | 2159 | """
|
@@ -2196,7 +2194,7 @@ class Gdal2TilesError(Exception):
|
2196 | 2194 | pass
|
2197 | 2195 |
|
2198 | 2196 |
|
2199 |
| -class GDAL2Tiles(object): |
| 2197 | +class GDAL2Tiles: |
2200 | 2198 | def __init__(self, input_file: str, output_folder: str, options: Options) -> None:
|
2201 | 2199 | """Constructor function - initialization"""
|
2202 | 2200 | self.out_drv = None
|
@@ -4463,7 +4461,7 @@ def worker_tile_details(
|
4463 | 4461 | return tile_job_info, tile_details
|
4464 | 4462 |
|
4465 | 4463 |
|
4466 |
| -class ProgressBar(object): |
| 4464 | +class ProgressBar: |
4467 | 4465 | def __init__(self, total_items: int, progress_cbk=gdal.TermProgress_nocb) -> None:
|
4468 | 4466 | self.total_items = total_items
|
4469 | 4467 | self.nb_items_done = 0
|
@@ -4632,7 +4630,7 @@ def multi_threaded_tiling(
|
4632 | 4630 | shutil.rmtree(os.path.dirname(conf.src_file))
|
4633 | 4631 |
|
4634 | 4632 |
|
4635 |
| -class DividedCache(object): |
| 4633 | +class DividedCache: |
4636 | 4634 | def __init__(self, nb_processes):
|
4637 | 4635 | self.nb_processes = nb_processes
|
4638 | 4636 |
|
|
0 commit comments