I am trying to generate tiles from an OpenStreetMap area with some CAD generated assets superimposed. I am using Generate XYZ tiles.
Can anyone see from the output below why the math domain error might be being generated?
I am quite new to QGIS and this is the first time I have tried to generate tiles in any GIS.
QGIS version: 3.22.1-Białowieża
QGIS code revision: 663dcf8fb9
Qt version: 5.15.2
Python version: 3.9.5
GDAL version: 3.3.2
GEOS version: 3.9.1-CAPI-1.14.2
PROJ version: Rel. 8.1.1, September 1st, 2021
PDAL version: 2.3.0 (git-version: Release)
Algorithm started at: 2021-12-07T15:41:32
Algorithm 'Generate XYZ tiles (Directory)' starting…
Input parameters:
{ 'BACKGROUND_COLOR' : QColor(21, 105, 30, 0), 'DPI' : 96, 'EXTENT' : '506152.007303635,506840.800587922,157942.918894197,158412.463830712 [EPSG:4326]', 'METATILESIZE' : 4, 'OUTPUT_DIRECTORY' : 'TEMPORARY_OUTPUT', 'OUTPUT_HTML' : 'TEMPORARY_OUTPUT', 'QUALITY' : 75, 'TILE_FORMAT' : 0, 'TILE_HEIGHT' : 256, 'TILE_WIDTH' : 256, 'TMS_CONVENTION' : False, 'ZOOM_MAX' : 4, 'ZOOM_MIN' : 0 }
Traceback (most recent call last):
File "/Applications/QGIS.app/Contents/MacOS/../Resources/python/plugins/processing/algs/qgis/TilesXYZ.py", line 578, in processAlgorithm
self.generate(writer, parameters, context, feedback)
File "/Applications/QGIS.app/Contents/MacOS/../Resources/python/plugins/processing/algs/qgis/TilesXYZ.py", line 290, in generate
metatiles = get_metatiles(self.wgs_extent, zoom, self.metatilesize)
File "/Applications/QGIS.app/Contents/MacOS/../Resources/python/plugins/processing/algs/qgis/TilesXYZ.py", line 124, in get_metatiles
right_tile, bottom_tile = deg2num(south_edge, east_edge, zoom)
File "/Applications/QGIS.app/Contents/MacOS/../Resources/python/plugins/processing/algs/qgis/TilesXYZ.py", line 72, in deg2num
ytile = int((1.0 - math.log(math.tan(lat_rad) + (1 / math.cos(lat_rad))) / math.pi) / 2.0 * n)
ValueError: math domain error
Execution failed after 0.01 seconds
Loading resulting layers Algorithm 'Generate XYZ tiles (Directory)' finished HTML output has been generated by this algorithm. Open the results dialog to check it.