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

feat!: improve stop points initialization #90

Merged
merged 8 commits into from
Dec 14, 2023

Conversation

leo-desbureaux-tellae
Copy link
Contributor

@leo-desbureaux-tellae leo-desbureaux-tellae commented Dec 14, 2023

  • new Operator parameter 'stop_points_from': allows providing a way to initialize stop points of the Operator
  • changed the init_stops function: now calls a stop point initialisation method depending on the value of the 'stop_points_from' parameter
  • added two new methods for stop point initialization:
    • initialize stop points from a GeoJSON containing Points. Provide the file name (ending with .geojson) as the 'stop_points_from' parameter. Calls the _stops_table_from_geojson method.
    • initialize stop points from GTFS. Provide 'stop_points_from'='gtfs'. Calls the _stops_table_from_gtfs method.
    • Other methods can be implemented and called by overriding the init_stops method.

moved "stop_points_from" in Operator's root parameters (from "operation_parameters")

options for the "stop_points_from" parameter are a geojson filename and "gtfs". Removed now unused "requests" option.
new methods _stops_table_from_geojson and _stops_table_from_gtfs, can be overriden in subclasses to provide a more precise set of stops using operator attributes.
@leo-desbureaux-tellae leo-desbureaux-tellae changed the title feat!: improve stop points initialisation feat!: improve stop points initialization Dec 14, 2023
@leo-desbureaux-tellae leo-desbureaux-tellae merged commit b62d07f into main Dec 14, 2023
@leo-desbureaux-tellae leo-desbureaux-tellae deleted the feat/improve_stop_points_init branch December 14, 2023 16:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant