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

Simulate with custom OD data? #31

Open
eth4io opened this issue Oct 7, 2019 · 4 comments
Open

Simulate with custom OD data? #31

eth4io opened this issue Oct 7, 2019 · 4 comments
Labels

Comments

@eth4io
Copy link

eth4io commented Oct 7, 2019

Trying to use the tool to simulate trajectories with a dataset of real OD data.
Is it possible with the current command line arguments?
If yes how should I prepare my OD data?

@morganherlocker
Copy link
Contributor

Check out the repo as of 1.0, when it was hardcoded to work with a simple OD file from NYC taxis. I would love to support custom OD data going forward, but this may be a helpful starting point to get an idea for how it worked.

https://github.com/sharedstreets/trip-simulator/tree/f9abdd0a2119668407c23f881917c77b054fcb66

@eth4io
Copy link
Author

eth4io commented Oct 15, 2019

Thanks for the info. I checked the code and learned it uses osrm data to route between real OD pair. If only the path is "faked" but the OD are still the original ones, does this mean the simulated paths are still quite sensitive? Reason is I think how a person get from A to B is not that important compare to where do they start a trip and more importantly where are they going.
I guess this was one of the reasons why you moved away from using existing OD data?

I'm thinking another way to make the simulation more realistic by utilising existing OD data.
With exisiting OD pairs, generate an OD probability cell map (eg. L15 s2 cells), then use this learned knowledge to help select starting point.
This could possibly works better if the life cycle of an agent can be limited, so that old agents can be dismissed and new agents can spawn during the simulation

@eth4io
Copy link
Author

eth4io commented Oct 15, 2019

The purpose of using custom OD data is to compare the result with

  1. real trajectory data captured by navigation apps
  2. simulated trajectory data with real OD data
  3. simulated trajectory with real OD distribution (what I'm trying to do)
  4. simulated trajectory with a distribution represented by population data

I've implemented this feature (with custom OD distribution) and started testing it with some data.
eth4io#1
Would like to hear your comment and happy to create PR if it's something on your roadmap

@morganherlocker
Copy link
Contributor

Ah, I see what you mean here. Yes, the original implementation had no modeling for the ODs at all. Using it as an input to the probability grid could be a good option. Another way I could see this working is using measurements from the OD dataset to guide the vehicle profile. Using the grid directly has some problems, particularly if your data is incomplete or insufficiently representative. I think you would ideally want a hybrid of OD density and the existing urban density model.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants