Skip to content

Commit

Permalink
correct error message upon too large error
Browse files Browse the repository at this point in the history
  • Loading branch information
jdegerickx committed Oct 16, 2024
1 parent 40ab443 commit 37c7013
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/worldcereal/utils/map.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import geopandas as gpd
import numpy as np
from ipyleaflet import DrawControl, LayersControl, Map, SearchControl, basemaps
from IPython.display import display
from ipywidgets import widgets
Expand All @@ -24,7 +25,7 @@ def handle_draw(instance, action, geo_json, output, area_limit):
if (area > area_limit) or (area > 750):
logger.error(
f"Area of processing extent is too large. "
f"Please select an area smaller than {area_limit} km²."
f"Please select an area smaller than {np.min([area_limit, 750])} km²."
)
instance.last_draw = {"type": "Feature", "geometry": None}

Expand Down

0 comments on commit 37c7013

Please sign in to comment.