var layerLoadErrorMessages=[];showMessage('Loading',staticTemplates.loadingModal[mode]);function runGeeViz(){Map.addSerializedLayer({"result": "0", "values": {"1": {"functionInvocationValue": {"functionName": "Geometry.bounds", "arguments": {"geometry": {"functionInvocationValue": {"functionName": "Geometry.buffer", "arguments": {"distance": {"constantValue": 25000}, "geometry": {"functionInvocationValue": {"functionName": "GeometryConstructors.Point", "arguments": {"coordinates": {"constantValue": [-111.891, 40.7608]}}}}}}}}}}, "0": {"functionInvocationValue": {"functionName": "Image.clip", "arguments": {"geometry": {"valueReference": "1"}, "input": {"functionInvocationValue": {"functionName": "reduce.median", "arguments": {"collection": {"functionInvocationValue": {"functionName": "Collection.filter", "arguments": {"collection": {"functionInvocationValue": {"functionName": "Collection.filter", "arguments": {"collection": {"functionInvocationValue": {"functionName": "Collection.filter", "arguments": {"collection": {"functionInvocationValue": {"functionName": "ImageCollection.load", "arguments": {"id": {"constantValue": "COPERNICUS/S2_SR_HARMONIZED"}}}}, "filter": {"functionInvocationValue": {"functionName": "Filter.intersects", "arguments": {"leftField": {"constantValue": ".all"}, "rightValue": {"functionInvocationValue": {"functionName": "Feature", "arguments": {"geometry": {"valueReference": "1"}}}}}}}}}}, "filter": {"functionInvocationValue": {"functionName": "Filter.dateRangeContains", "arguments": {"leftValue": {"functionInvocationValue": {"functionName": "DateRange", "arguments": {"end": {"constantValue": "2026-02-27"}, "start": {"constantValue": "2025-12-01"}}}}, "rightField": {"constantValue": "system:time_start"}}}}}}}, "filter": {"functionInvocationValue": {"functionName": "Filter.lessThan", "arguments": {"leftField": {"constantValue": "CLOUDY_PIXEL_PERCENTAGE"}, "rightValue": {"constantValue": 40}}}}}}}}}}}}}}},{"min": 0, "max": [0.2, 0.2, 0.2], "bands": "red,green,blue", "layerType": "geeImage"},'S2 Composite True Color',false);Map.addSerializedLayer({"result": "0", "values": {"1": {"functionInvocationValue": {"functionName": "Geometry.bounds", "arguments": {"geometry": {"functionInvocationValue": {"functionName": "Geometry.buffer", "arguments": {"distance": {"constantValue": 25000}, "geometry": {"functionInvocationValue": {"functionName": "GeometryConstructors.Point", "arguments": {"coordinates": {"constantValue": [-111.891, 40.7608]}}}}}}}}}}, "0": {"functionInvocationValue": {"functionName": "Image.clip", "arguments": {"geometry": {"valueReference": "1"}, "input": {"functionInvocationValue": {"functionName": "reduce.median", "arguments": {"collection": {"functionInvocationValue": {"functionName": "Collection.filter", "arguments": {"collection": {"functionInvocationValue": {"functionName": "Collection.filter", "arguments": {"collection": {"functionInvocationValue": {"functionName": "Collection.filter", "arguments": {"collection": {"functionInvocationValue": {"functionName": "ImageCollection.load", "arguments": {"id": {"constantValue": "COPERNICUS/S2_SR_HARMONIZED"}}}}, "filter": {"functionInvocationValue": {"functionName": "Filter.intersects", "arguments": {"leftField": {"constantValue": ".all"}, "rightValue": {"functionInvocationValue": {"functionName": "Feature", "arguments": {"geometry": {"valueReference": "1"}}}}}}}}}}, "filter": {"functionInvocationValue": {"functionName": "Filter.dateRangeContains", "arguments": {"leftValue": {"functionInvocationValue": {"functionName": "DateRange", "arguments": {"end": {"constantValue": "2026-02-27"}, "start": {"constantValue": "2025-12-01"}}}}, "rightField": {"constantValue": "system:time_start"}}}}}}}, "filter": {"functionInvocationValue": {"functionName": "Filter.lessThan", "arguments": {"leftField": {"constantValue": "CLOUDY_PIXEL_PERCENTAGE"}, "rightValue": {"constantValue": 40}}}}}}}}}}}}}}},{"min": 0.05, "max": [0.5, 0.6, 0.6], "bands": "swir1,nir,red", "gamma": 1.6, "layerType": "geeImage"},'S2 Composite False Color',true);if(layerLoadErrorMessages.length>0){showMessage("Map.addLayer Error List",layerLoadErrorMessages.join("<br>"));};setTimeout(function(){if(layerLoadErrorMessages.length===0){$('#close-modal-button').click();}}, 2500);synchronousCenterObject({"geodesic": false, "type": "Polygon", "coordinates": [[[-112.18546945069338, 40.535914514919774], [-111.59536866080693, 40.535914514919774], [-111.59536866080693, 40.985771648787065], [-112.18546945069338, 40.985771648787065], [-112.18546945069338, 40.535914514919774]]]});map.setZoom(10);queryWindowMode = "sidePane";Map.turnOffLayersWhenTimeLapseIsOn = true;};