Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UNA: NameError name 'expected_distance' is not defined #1579

Closed
davemfish opened this issue May 21, 2024 · 2 comments
Closed

UNA: NameError name 'expected_distance' is not defined #1579

davemfish opened this issue May 21, 2024 · 2 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@davemfish
Copy link
Contributor

Yingjie reports:

I run the model with the same setting and the model reported the same error. I attached her log file for your reference.

  • search_radius_mode: uniform radius
  • decay_function: exponential
2024-05-19 10:55:29,083 (natcap.invest.utils) utils.prepare_workspace(161) Level 100 Writing log messages to [E:\invest\urban nature access\demo3\InVEST-natcap.invest.urban_nature_access-log-2024-05-19--10_55_29.txt]
2024-05-19 10:55:29,083 (__main__) cli.main(459) Level 100 Starting model with parameters: 
Arguments for InVEST natcap.invest.urban_nature_access 3.14.1:
admin_boundaries_vector_path E:\invest\urban nature access\data\UrbanNatureAccess\administrative-units.shp
aggregate_by_pop_group       True
decay_function               exponential
lulc_attribute_table         E:\invest\urban nature access\data\UrbanNatureAccess\lulc-attributes.csv
lulc_raster_path             E:\invest\urban nature access\data\UrbanNatureAccess\paris-lulc.tif
n_workers                    -1
population_group_radii_table E:\invest\urban nature access\data\UrbanNatureAccess\pop-group-radii.csv
population_raster_path       E:\invest\urban nature access\data\UrbanNatureAccess\population.tif
results_suffix               
search_radius                200
search_radius_mode           uniform radius
urban_nature_demand          11
workspace_dir                E:\invest\urban nature access\demo3

2024-05-19 10:55:29,083 (natcap.invest.urban_nature_access) urban_nature_access.execute(697) INFO Starting Urban Nature Access Model
2024-05-19 10:55:29,087 (natcap.invest.urban_nature_access) urban_nature_access.execute(732) INFO Using decay function exponential
2024-05-19 10:55:29,868 (natcap.invest.utils) utils.prepare_workspace(166) ERROR Exception while executing natcap.invest.urban_nature_access
Traceback (most recent call last):
  File "natcap\invest\utils.py", line 164, in prepare_workspace
  File "invest\cli.py", line 470, in main
  File "natcap\invest\urban_nature_access.py", line 977, in execute
NameError: name 'expected_distance' is not defined
2024-05-19 10:55:29,869 (natcap.invest.utils) utils.prepare_workspace(169) INFO Elapsed time: 0.79s
2024-05-19 10:55:29,869 (natcap.invest.utils) utils.prepare_workspace(172) INFO Execution finished
@davemfish davemfish added the bug Something isn't working label May 21, 2024
@davemfish davemfish added this to the 3.14.2 milestone May 21, 2024
@davemfish davemfish self-assigned this May 21, 2024
@davemfish
Copy link
Contributor Author

@phargogh turns out this NameError does not exist on main. I tested the model with the parameters that used to trigger it. All good.

@davemfish
Copy link
Contributor Author

This was a duplicate all along. #1502

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant