mirror of
https://git.ianrenton.com/ian/spothole.git
synced 2026-09-20 22:37:44 +00:00
ruff fixes
This commit is contained in:
+2
-2
@@ -1,6 +1,6 @@
|
||||
import logging
|
||||
import re
|
||||
from math import floor
|
||||
from math import floor, isnan
|
||||
|
||||
from pyproj import Transformer
|
||||
from shapely.geometry import Point, Polygon
|
||||
@@ -156,7 +156,7 @@ def lat_lon_for_grid_sw_corner_plus_size(grid):
|
||||
lat -= 90.0
|
||||
|
||||
# Return None values on maths errors
|
||||
if any(x != x for x in [lat, lon, lat_cell_size, lon_cell_size]):
|
||||
if any(isnan(x) for x in [lat, lon, lat_cell_size, lon_cell_size]):
|
||||
return None, None, None, None
|
||||
|
||||
return lat, lon, lat_cell_size, lon_cell_size
|
||||
|
||||
Reference in New Issue
Block a user