-
Notifications
You must be signed in to change notification settings - Fork 57
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
Use Custom Pandana Network/Weights #52
Comments
Hi @d-wasserman, Thanks for the heads up on vincenty, we can update that to use the new recommended function in the next version of UrbanAccess and update the docs to make it clear coordinates need to be WGS84. Added it as new issue here: #53 Yes your code snippet would accomplish what you want without any other modifications to urbanaccess. Essentially you are trying to replicate what happens here: https://github.com/UDST/urbanaccess/blob/dev/urbanaccess/osm/network.py when the OSM network is set to equal the urbanacces OSM network objects so what you have there looks correct. To generalize this some data validation checks could be placed in that function (as well as data schema additions to docs) to ensure that the custom network can work with other urbanaccess processes down the line without any further modifications. These would include: The graph network must be a directed graph (e.g. in pandana terminology it must be an explicit oneway network where each edge where two direction travel is possible the edge must occur twice with directionality inferred by the IDs in the In terms of the data schema for the resulting network objects:
Long term solution would be to generalize this so that the OSM network is optional so you dont need it and can instead choose to use a custom network like what you have here that has its own set of generalized urbanaccess network objects so its clear in the API. So Ill add this to the development roadmap barring any PRs from anyone who would like to take this on now. |
Hi Sam, No problem on vincenty. Thought you would like to know. Agreed on all points. I might be interested in adding a PR including validation if that would help. One clarification: do you mean minutes instead of seconds for the weight? |
Ok sounds good @d-wasserman ! Yes for sure PRs are welcome and we can take a look when its in. Yes sorry about that, my mixup, it is |
This is definitely an enhancement idea:
It seems that currently the assumption is the street network is pulled from OSM, but there is little stopping it from using an arbitrary pandana network already created. What is the possibility of integrating custom travel networks?
Generally, I think this is possible, but the big concern I have here is you can't set the CRS assumptions for urbanaccess because of its use of the vincenty function from geopy (which will be removed in 2.0 as an FYI). So you will have to set the pandana network to WGS 1984, but we could document that.
Curious what your thoughts on this might be @sablanchard.
I implemented this with the following as a quick draft, and I think it works (same principle as loading OSM, but loading WGS 1984 projected edges/nodes).
The text was updated successfully, but these errors were encountered: