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

Generate fare information #105

Open
AltNico opened this issue Dec 17, 2017 · 7 comments
Open

Generate fare information #105

AltNico opened this issue Dec 17, 2017 · 7 comments

Comments

@AltNico
Copy link
Collaborator

AltNico commented Dec 17, 2017

GTFS lets agencies specify fare (i.e. price) information. We should think about how we can include this information into the generation of GTFS with osm2gtfs. You can find the reference here.

Note that Transportr does not support this information yet.

@ialokim
Copy link
Contributor

ialokim commented Jan 4, 2018

The official GTFS specification only supports one Rider category, thus the regular, adult fare. I've found this GTFS extension used by the SF Bay Area's Metropolitan Transportation Commission which supports additional categories. Could be interesting some time in the future, but as far as I know isn't supported (yet?) by Navitia.

@ialokim
Copy link
Contributor

ialokim commented Jan 4, 2018

As for now, how about an option to include a (as by now) not automatically generated txt-file given by the configuration?
Could be interesting for:

  • calendar_dates.txt
  • fare_attributes.txt
  • fare_rules.txt
  • frequencies.txt
  • transfers.txt

Personally, I've wanted to include the (very simple) fare information for Estelí, but it would be much nicer not having to add it manually every time we've generated a new GTFS.

@ialokim
Copy link
Contributor

ialokim commented Jan 5, 2018

I've created a first draft in the wiki for a possible fare input format. It is another json file, similar to the Schedule and would work well for the case of Nicaragua:

  • In Esteli, the urban buses generally cost 5 Córdobas, for some destinations up to 8 Córdobas.
  • In Managua, all urban buses cost 2.5 Córdobas.
  • Larger distance buses generally have prizes given by the government in the following form (example for a bus from Esteli to Managua):
origin destination prize
Esteli Santa Cruz 12 C$
Esteli Sébaco 30 C$
Sébaco Tipitapa 40 C$
Sébaco Managua 45 C$

The proposed format introduces fare zones as in GTFS and let you define which stops are within which fare zone and the prize of a journey from one fare zone to another. Also, it is possible to override these prizes (e.g. for more expensive express buses).

Estelí urban buses would have like three of these fare zones, Managua only one and the above table could be easily converted and put into this format.

Please note that there would be another file with another start and end date. See #111.

@ialokim
Copy link
Contributor

ialokim commented Feb 2, 2018

@prhod and @nlehuby: I was just wondering, whether fare information from GTFS is imported and used by Navitia or not? 🤔

@prhod
Copy link
Collaborator

prhod commented Feb 3, 2018

@ialokim For the moment, fare information are not read directly from gtfs. We plan to do it, but it will take time. I hope we will be able to do it before the end of the year...

@ialokim
Copy link
Contributor

ialokim commented Feb 16, 2018

@prhod Thanks for your answer! Great to hear you are working on it!

@ialokim
Copy link
Contributor

ialokim commented Feb 17, 2018

I've now written a first basic implementation for Estelí that only supports a fare per route, see the proposed fares.json here and the working branch here.

Due to the poor fare possibilities in GTFS, it is not possible to model fares on a per weekday basis (which would be necessary for Esteli), so it is using the same fare every day of the week.

The second step would be to implement the possibility of generating fare zones as proposed in the wiki and necessitated by the countrywide GTFS, see here.

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

No branches or pull requests

3 participants