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

client demand and facility capacity is transposed in LSCP.from_geodataframe() #410

Closed
Tracked by #414
ljwolf opened this issue Dec 2, 2023 · 1 comment
Closed
Tracked by #414
Assignees
Labels
bug Something isn't working locate

Comments

@ljwolf
Copy link
Member

ljwolf commented Dec 2, 2023

In the from_cost_method() function definition, demand weight comes first:

https://github.com/pysal/spopt/blob/main/spopt/locate/coverage.py#L126

However, from_geodataframe() passes the facility capacities first:

https://github.com/pysal/spopt/blob/main/spopt/locate/coverage.py#L455

This makes it hard to use the capacities, since any situation where capacity is bigger than the demand will get rejected erroneously as if capacity were smaller than the demand.

A fix is both easy and immediate. I can make this change, and would really appreciate a bug fix release this week before teaching the module in Tartu?

@ljwolf ljwolf mentioned this issue Dec 2, 2023
@jGaboardi jGaboardi added bug Something isn't working locate labels Dec 2, 2023
@jGaboardi
Copy link
Member

Resolved via #411 – will close issue following release.

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

No branches or pull requests

2 participants