Spaces:
Sleeping
Sleeping
nastasiasnk
commited on
Commit
•
9125b7b
1
Parent(s):
17b4ded
Update app.py
Browse files
app.py
CHANGED
@@ -171,8 +171,8 @@ def test(input_json):
|
|
171 |
|
172 |
for key, values in SubdomainAttributeDict.items():
|
173 |
if key == 'commercial':
|
174 |
-
threshold = float(SubdomainAttributeDict['commercial'][
|
175 |
-
max_livability = float(SubdomainAttributeDict['commercial'][
|
176 |
livability_score = remap(subdomainsAccessibility['jobs'], 0, threshold, 0, max_livability)
|
177 |
livability.loc[subdomainsAccessibility['jobs'] >= threshold, 'Workplaces'] = max_livability
|
178 |
livability.loc[subdomainsAccessibility['jobs'] < threshold, 'Workplaces'] = livability_score
|
|
|
171 |
|
172 |
for key, values in SubdomainAttributeDict.items():
|
173 |
if key == 'commercial':
|
174 |
+
threshold = float(SubdomainAttributeDict['commercial']['thresholds'])
|
175 |
+
max_livability = float(SubdomainAttributeDict['commercial']['max_points'])
|
176 |
livability_score = remap(subdomainsAccessibility['jobs'], 0, threshold, 0, max_livability)
|
177 |
livability.loc[subdomainsAccessibility['jobs'] >= threshold, 'Workplaces'] = max_livability
|
178 |
livability.loc[subdomainsAccessibility['jobs'] < threshold, 'Workplaces'] = livability_score
|