Skip to content
This repository has been archived by the owner on Dec 8, 2022. It is now read-only.

Expand transfers from station to sub-stop #22

Open
laurentg opened this issue Jan 21, 2016 · 2 comments
Open

Expand transfers from station to sub-stop #22

laurentg opened this issue Jan 21, 2016 · 2 comments

Comments

@laurentg
Copy link
Contributor

(Extract from WIKI GTFS' model)

Proposal: expansion of transfers

In GTFS, a transfer that is defined for a station will apply, if not redefined, to all the station stops. A proposal to GTFS' is to expand any station transfer to sub-stops, if a transfer is not already redefined for the stops.

Goal: to provide for the API user an easy access of transfers between stops w/o having to check for transfers between stations. The check/load sequence can be rather complex (stop to stop, stop to station, station to stop, station to station...)

For example let's assume we have station A with stops A1 and A2, and station B with stops B1 and B2, and the following transfers:

from   to   type
A      B    0
A1     B1   3
B      A    1
B1     A    3

The transfer expansion process would expand to the following:

from   to   type   source
A      B    0      Original
A1     B1   3      Original
A1     B2   0      Expanded
A2     B1   0      Expanded
A2     B2   0      Expanded
B      A    1      Original
B1     A    3      Original
B1     A1   3      Expanded
B1     A2   3      Expanded
B2     A1   1      Expanded
B2     A2   1      Expanded
@laurentg
Copy link
Contributor Author

This should be made optional as for some input data (many stations with many stops) the generated data can grow quite large.

@laurentg
Copy link
Contributor Author

Another idea is to "generate" those virtual transfers at the DAO or service layer, with query functions that automatically generate missing transfers according to those expansion rules.

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

No branches or pull requests

1 participant