nastasiasnk commited on
Commit
3edcc97
1 Parent(s): 2bf56e3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -2
app.py CHANGED
@@ -190,8 +190,11 @@ def test(input_json):
190
  valid_indexes = [idx for idx in mask_connected if idx in dfLanduses.index]
191
  missing_indexes = set(mask_connected) - set(valid_indexes)
192
  if missing_indexes:
193
- indexError = f"Error: The following indexes were not found in the DataFrame: {missing_indexes}, length: {len(missing_indexes)}"
194
-
 
 
 
195
 
196
  accessibilityStats = [
197
  f"{column} = {subdomainsAccessibility[column].min()}, {subdomainsAccessibility[column].max()}, {subdomainsAccessibility[column].mean()}" for column in subdomainsAccessibility.columns
 
190
  valid_indexes = [idx for idx in mask_connected if idx in dfLanduses.index]
191
  missing_indexes = set(mask_connected) - set(valid_indexes)
192
  if missing_indexes:
193
+ indexError = f"Error: The following indexes were not found in the Landuse dataframe: {missing_indexes}, length: {len(missing_indexes)}"
194
+ else:
195
+ indexError = "No missing indexes found in the Landuse dataframe."
196
+
197
+
198
 
199
  accessibilityStats = [
200
  f"{column} = {subdomainsAccessibility[column].min()}, {subdomainsAccessibility[column].max()}, {subdomainsAccessibility[column].mean()}" for column in subdomainsAccessibility.columns