Skip to content

Commit 8cd6c90

Browse files
committed
err towards wider zoom in plotly
1 parent 8057e54 commit 8cd6c90

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

gnss_lib_py/utils/visualizations.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77

88
import os
99
import pathlib
10+
from math import floor
1011
from multiprocessing import Process
1112

1213
import numpy as np
@@ -806,7 +807,7 @@ def _zoom_center(lats, lons, width_to_height = 1.25):
806807
width = (maxlon - minlon) * margin
807808
lon_zoom = np.interp(width , lon_zoom_range, range(20, 0, -1))
808809
lat_zoom = np.interp(height, lon_zoom_range, range(20, 0, -1))
809-
zoom = round(min(lon_zoom, lat_zoom), 2)
810+
zoom = floor(min(lon_zoom, lat_zoom))
810811

811812
return zoom, center
812813

0 commit comments

Comments
 (0)