r5py 1.0.0.dev12__tar.gz → 1.0.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of r5py might be problematic. Click here for more details.
- r5py-1.0.2/MANIFEST.in +3 -0
- {r5py-1.0.0.dev12/src/r5py.egg-info → r5py-1.0.2}/PKG-INFO +7 -6
- {r5py-1.0.0.dev12 → r5py-1.0.2}/README.md +4 -4
- {r5py-1.0.0.dev12 → r5py-1.0.2}/pyproject.toml +3 -2
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/__init__.py +1 -1
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/__init__.py +0 -2
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/regional_task.py +0 -31
- {r5py-1.0.0.dev12 → r5py-1.0.2/src/r5py.egg-info}/PKG-INFO +7 -6
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py.egg-info/SOURCES.txt +40 -3
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py.egg-info/requires.txt +3 -0
- r5py-1.0.2/tests/__init__.py +3 -0
- r5py-1.0.2/tests/conftest.py +13 -0
- r5py-1.0.2/tests/conftest_d/__init__.py +148 -0
- r5py-1.0.2/tests/conftest_d/data_directory.py +8 -0
- r5py-1.0.2/tests/conftest_d/destinations.py +83 -0
- r5py-1.0.2/tests/conftest_d/file_digest.py +48 -0
- r5py-1.0.2/tests/conftest_d/garbage_collection.py +14 -0
- r5py-1.0.2/tests/conftest_d/origins.py +72 -0
- r5py-1.0.2/tests/conftest_d/r5_jar.py +57 -0
- r5py-1.0.2/tests/conftest_d/routing_parameters.py +33 -0
- r5py-1.0.2/tests/conftest_d/routing_results.py +141 -0
- r5py-1.0.2/tests/conftest_d/sample_data.py +25 -0
- r5py-1.0.2/tests/conftest_d/transport_network.py +98 -0
- r5py-1.0.2/tests/conftest_d/upstream_r5.py +19 -0
- r5py-1.0.2/tests/data/test_detailed_itineraries_bicycle.gpkg.zip +0 -0
- r5py-1.0.2/tests/data/test_detailed_itineraries_car.gpkg.zip +0 -0
- r5py-1.0.2/tests/data/test_detailed_itineraries_transit.gpkg.zip +0 -0
- r5py-1.0.2/tests/data/test_detailed_itineraries_walk.gpkg.zip +0 -0
- r5py-1.0.2/tests/data/test_invalid_points_duplicate_ids.geojson +10 -0
- r5py-1.0.2/tests/data/test_invalid_points_no_id_column.geojson +11 -0
- r5py-1.0.2/tests/data/test_isochrones_bicycle.gpkg.zip +0 -0
- r5py-1.0.2/tests/data/test_isochrones_car.gpkg.zip +0 -0
- r5py-1.0.2/tests/data/test_isochrones_from_multiple_origins.gpkg.zip +0 -0
- r5py-1.0.2/tests/data/test_isochrones_transit.gpkg.zip +0 -0
- r5py-1.0.2/tests/data/test_isochrones_walk.gpkg.zip +0 -0
- r5py-1.0.2/tests/data/test_multiple_origins.geojson +10 -0
- r5py-1.0.2/tests/data/test_snapped_population_grid_centroids.geojson +98 -0
- r5py-1.0.2/tests/data/test_travel_times_bicycle.csv +362 -0
- r5py-1.0.2/tests/data/test_travel_times_car.csv +362 -0
- r5py-1.0.2/tests/data/test_travel_times_transit.csv +362 -0
- r5py-1.0.2/tests/data/test_travel_times_walk.csv +362 -0
- r5py-1.0.2/tests/data/test_valid_points_data.geojson +11 -0
- r5py-1.0.2/tests/data/test_valid_single_point_data.geojson +7 -0
- r5py-1.0.2/tests/data/test_walking_details_not_snapped.csv +362 -0
- r5py-1.0.2/tests/data/test_walking_details_snapped.csv +362 -0
- r5py-1.0.2/tests/data/test_walking_times_not_snapped.csv +8465 -0
- r5py-1.0.2/tests/data/test_walking_times_snapped.csv +8465 -0
- r5py-1.0.2/tests/temporary_directory.py +32 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_regional_task.py +17 -11
- r5py-1.0.0.dev12/src/r5py/r5/breakdown_stat.py +0 -26
- r5py-1.0.0.dev12/tests/test_breakdownstats.py +0 -30
- {r5py-1.0.0.dev12 → r5py-1.0.2}/LICENSE +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/setup.cfg +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/__main__.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/access_leg.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/base_travel_time_matrix.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/detailed_itineraries.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/direct_leg.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/egress_leg.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/isochrones.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/scenario.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/street_layer.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/street_segment.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/transfer_leg.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/transit_layer.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/transit_leg.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/transport_mode.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/transport_network.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/travel_time_matrix.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/trip.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/trip_leg.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/r5/trip_planner.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/__init__.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/camel_to_snake_case.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/classpath.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/config.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/contains_gtfs_data.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/data_validation.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/environment.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/exceptions.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/file_digest.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/good_enough_equidistant_crs.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/jvm.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/memory_footprint.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/parse_int_date.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/sample_data_set.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/snake_to_camel_case.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/spatially_clustered_geodataframe.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/validating_requests_session.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/warnings.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py/util/working_copy.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py.egg-info/dependency_links.txt +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/src/r5py.egg-info/top_level.txt +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_camel_to_snake_case.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_classpath.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_config.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_contains_gtfs_data.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_data_validation.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_detailed_itineraries.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_deterministic_behaviour.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_file_digest.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_good_enough_equidistant_crs.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_isochrones.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_java_casting.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_memory_footprint.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_parse_int_date.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_sample_data_set.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_snake_to_camel_case.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_street_layer.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_transit_layer.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_transport_mode.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_transport_network.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_travel_time_matrix.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_trip.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_trip_leg.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_trip_planner.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_validating_request_session.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_verbose_warnings.py +0 -0
- {r5py-1.0.0.dev12 → r5py-1.0.2}/tests/test_working_directory.py +0 -0
r5py-1.0.2/MANIFEST.in
ADDED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.2
|
|
2
2
|
Name: r5py
|
|
3
|
-
Version: 1.0.
|
|
3
|
+
Version: 1.0.2
|
|
4
4
|
Summary: Python wrapper for the R5 routing analysis engine
|
|
5
5
|
Author: Christoph Fink, Willem Klumpenhouwer, Marcus Sairava, Rafael Pereira, Henrikki Tenkanen
|
|
6
6
|
License: GPL-3.0-or-later or MIT
|
|
@@ -13,7 +13,7 @@ Classifier: Programming Language :: Python :: 3
|
|
|
13
13
|
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
|
|
14
14
|
Classifier: License :: OSI Approved :: MIT License
|
|
15
15
|
Classifier: Operating System :: OS Independent
|
|
16
|
-
Requires-Python: >=3.
|
|
16
|
+
Requires-Python: >=3.10
|
|
17
17
|
Description-Content-Type: text/markdown
|
|
18
18
|
License-File: LICENSE
|
|
19
19
|
Requires-Dist: ConfigArgParse
|
|
@@ -30,6 +30,7 @@ Requires-Dist: requests
|
|
|
30
30
|
Requires-Dist: scikit-learn
|
|
31
31
|
Requires-Dist: shapely>=2.0
|
|
32
32
|
Requires-Dist: simplification
|
|
33
|
+
Requires-Dist: typing_extensions; python_version < "3.13"
|
|
33
34
|
Provides-Extra: docs
|
|
34
35
|
Requires-Dist: contextily; extra == "docs"
|
|
35
36
|
Requires-Dist: folium; extra == "docs"
|
|
@@ -70,7 +71,7 @@ Requires-Dist: typing-extensions; extra == "tests"
|
|
|
70
71
|
[![downloads (pypi)][downloads-pypi-badge]][downloads-pypi-link]
|
|
71
72
|
[![downloads (conda-forge)][downloads-conda-forge-badge]][downloads-conda-forge-link]
|
|
72
73
|
<br />
|
|
73
|
-
[![
|
|
74
|
+
[![Unit tests][test-status-badge]][test-status-link]
|
|
74
75
|
[![Documentation Status][rtd-status-badge]][rtd-status-link]
|
|
75
76
|
[![Coverage][coverage-badge]][coverage-link]
|
|
76
77
|
<br />
|
|
@@ -137,9 +138,7 @@ your project better.
|
|
|
137
138
|
|
|
138
139
|
<!-- (1) badges -->
|
|
139
140
|
[binder-badge]: https://img.shields.io/badge/Try%20r5py%20with-binder-F5A252.svg?logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAFkAAABZCAMAAABi1XidAAAB8lBMVEX///9XmsrmZYH1olJXmsr1olJXmsrmZYH1olJXmsr1olJXmsrmZYH1olL1olJXmsr1olJXmsrmZYH1olL1olJXmsrmZYH1olJXmsr1olL1olJXmsrmZYH1olL1olJXmsrmZYH1olL1olL0nFf1olJXmsrmZYH1olJXmsq8dZb1olJXmsrmZYH1olJXmspXmspXmsr1olL1olJXmsrmZYH1olJXmsr1olL1olJXmsrmZYH1olL1olLeaIVXmsrmZYH1olL1olL1olJXmsrmZYH1olLna31Xmsr1olJXmsr1olJXmsrmZYH1olLqoVr1olJXmsr1olJXmsrmZYH1olL1olKkfaPobXvviGabgadXmsqThKuofKHmZ4Dobnr1olJXmsr1olJXmspXmsr1olJXmsrfZ4TuhWn1olL1olJXmsqBi7X1olJXmspZmslbmMhbmsdemsVfl8ZgmsNim8Jpk8F0m7R4m7F5nLB6jbh7jbiDirOEibOGnKaMhq+PnaCVg6qWg6qegKaff6WhnpKofKGtnomxeZy3noG6dZi+n3vCcpPDcpPGn3bLb4/Mb47UbIrVa4rYoGjdaIbeaIXhoWHmZYHobXvpcHjqdHXreHLroVrsfG/uhGnuh2bwj2Hxk17yl1vzmljzm1j0nlX1olL3AJXWAAAAbXRSTlMAEBAQHx8gICAuLjAwMDw9PUBAQEpQUFBXV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tCW8HHGJc2R5hS219IiF6PnTusOqcMl57gm0Z8kanKMAQg0qSyuZfn7zItsbGyO9QlnxY0eCuD1XL2ys/MsrQhltE7Ug0uFOzufJFE2PxBo/YAx8XPPdDwWN0MrDRYIZF0mSMKCNHgaIVFoBbNoLJ7tEQDKxGF0kcLQimojCZopv0OkNOyWCCg9XMVAi7ARJzQdM2QUh0gmBozjc3Skg6dSBRqDGYSUOu66Zg+I2fNZs/M3/f/Grl/XnyF1Gw3VKCez0PN5IUfFLqvgUN4C0qNqYs5YhPL+aVZYDE4IpUk57oSFnJm4FyCqqOE0jhY2SMyLFoo56zyo6becOS5UVDdj7Vih0zp+tcMhwRpBeLyqtIjlJKAIZSbI8SGSF3k0pA3mR5tHuwPFoa7N7reoq2bqCsAk1HqCu5uvI1n6JuRXI+S1Mco54YmYTwcn6Aeic+kssXi8XpXC4V3t7/ADuTNKaQJdScAAAAAElFTkSuQmCC
|
|
140
|
-
[binder-link]: https://
|
|
141
|
-
[build-status-badge]: https://github.com/r5py/r5py/actions/workflows/build-merged-pull-requests.yml/badge.svg
|
|
142
|
-
[build-status-link]: https://github.com/r5py/r5py/actions/workflows/build-merged-pull-requests.yml
|
|
141
|
+
[binder-link]: https://mybinder.org/v2/gh/r5py/r5py/stable?urlpath=tree/docs/user-guide/user-manual/quickstart.md
|
|
143
142
|
[coverage-badge]: https://codecov.io/gh/r5py/r5py/branch/main/graph/badge.svg?token=WG8RBMZBK6
|
|
144
143
|
[coverage-link]: https://codecov.io/gh/r5py/r5py
|
|
145
144
|
[doi-badge]: https://zenodo.org/badge/DOI/10.5281/zenodo.7060437.svg
|
|
@@ -152,6 +151,8 @@ your project better.
|
|
|
152
151
|
[rtd-status-link]: https://r5py.readthedocs.io/
|
|
153
152
|
[stable-version-badge]: https://img.shields.io/pypi/v/r5py?label=Stable
|
|
154
153
|
[stable-version-link]: https://github.com/r5py/r5py/releases
|
|
154
|
+
[test-status-badge]: https://github.com/r5py/r5py/actions/workflows/test.yml/badge.svg
|
|
155
|
+
[test-status-link]: https://github.com/r5py/r5py/actions/workflows/test.yml
|
|
155
156
|
|
|
156
157
|
<!-- (2) other links -->
|
|
157
158
|
[conda-create-env-from-yml]: https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html#creating-an-environment-from-an-environment-yml-file
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
[![downloads (pypi)][downloads-pypi-badge]][downloads-pypi-link]
|
|
11
11
|
[![downloads (conda-forge)][downloads-conda-forge-badge]][downloads-conda-forge-link]
|
|
12
12
|
<br />
|
|
13
|
-
[![
|
|
13
|
+
[![Unit tests][test-status-badge]][test-status-link]
|
|
14
14
|
[![Documentation Status][rtd-status-badge]][rtd-status-link]
|
|
15
15
|
[![Coverage][coverage-badge]][coverage-link]
|
|
16
16
|
<br />
|
|
@@ -77,9 +77,7 @@ your project better.
|
|
|
77
77
|
|
|
78
78
|
<!-- (1) badges -->
|
|
79
79
|
[binder-badge]: https://img.shields.io/badge/Try%20r5py%20with-binder-F5A252.svg?logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAFkAAABZCAMAAABi1XidAAAB8lBMVEX///9XmsrmZYH1olJXmsr1olJXmsrmZYH1olJXmsr1olJXmsrmZYH1olL1olJXmsr1olJXmsrmZYH1olL1olJXmsrmZYH1olJXmsr1olL1olJXmsrmZYH1olL1olJXmsrmZYH1olL1olL0nFf1olJXmsrmZYH1olJXmsq8dZb1olJXmsrmZYH1olJXmspXmspXmsr1olL1olJXmsrmZYH1olJXmsr1olL1olJXmsrmZYH1olL1olLeaIVXmsrmZYH1olL1olL1olJXmsrmZYH1olLna31Xmsr1olJXmsr1olJXmsrmZYH1olLqoVr1olJXmsr1olJXmsrmZYH1olL1olKkfaPobXvviGabgadXmsqThKuofKHmZ4Dobnr1olJXmsr1olJXmspXmsr1olJXmsrfZ4TuhWn1olL1olJXmsqBi7X1olJXmspZmslbmMhbmsdemsVfl8ZgmsNim8Jpk8F0m7R4m7F5nLB6j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yx0eoy9uPzN5SPd86aXggOsEKW2Prz7du3VID3/tzs/sSRs2w7ovVHKtjrX2pd7ZMlTxAYfBAL9jiDwfLkq55Tm7ifhMlTGPyCAs7RFRhn47JnlcB9RM5T97ASuZXIcVNuUDIndpDbdsfrqsOppeXl5Y+XVKdjFCTh+zGaVuj0d9zy05PPK3QzBamxdwtTCrzyg/2Rvf2EstUjordGwa/kx9mSJLr8mLLtCW8HHGJc2R5hS219IiF6PnTusOqcMl57gm0Z8kanKMAQg0qSyuZfn7zItsbGyO9QlnxY0eCuD1XL2ys/MsrQhltE7Ug0uFOzufJFE2PxBo/YAx8XPPdDwWN0MrDRYIZF0mSMKCNHgaIVFoBbNoLJ7tEQDKxGF0kcLQimojCZopv0OkNOyWCCg9XMVAi7ARJzQdM2QUh0gmBozjc3Skg6dSBRqDGYSUOu66Zg+I2fNZs/M3/f/Grl/XnyF1Gw3VKCez0PN5IUfFLqvgUN4C0qNqYs5YhPL+aVZYDE4IpUk57oSFnJm4FyCqqOE0jhY2SMyLFoo56zyo6becOS5UVDdj7Vih0zp+tcMhwRpBeLyqtIjlJKAIZSbI8SGSF3k0pA3mR5tHuwPFoa7N7reoq2bqCsAk1HqCu5uvI1n6JuRXI+S1Mco54YmYTwcn6Aeic+kssXi8XpXC4V3t7/ADuTNKaQJdScAAAAAElFTkSuQmCC
|
|
80
|
-
[binder-link]: https://
|
|
81
|
-
[build-status-badge]: https://github.com/r5py/r5py/actions/workflows/build-merged-pull-requests.yml/badge.svg
|
|
82
|
-
[build-status-link]: https://github.com/r5py/r5py/actions/workflows/build-merged-pull-requests.yml
|
|
80
|
+
[binder-link]: https://mybinder.org/v2/gh/r5py/r5py/stable?urlpath=tree/docs/user-guide/user-manual/quickstart.md
|
|
83
81
|
[coverage-badge]: https://codecov.io/gh/r5py/r5py/branch/main/graph/badge.svg?token=WG8RBMZBK6
|
|
84
82
|
[coverage-link]: https://codecov.io/gh/r5py/r5py
|
|
85
83
|
[doi-badge]: https://zenodo.org/badge/DOI/10.5281/zenodo.7060437.svg
|
|
@@ -92,6 +90,8 @@ your project better.
|
|
|
92
90
|
[rtd-status-link]: https://r5py.readthedocs.io/
|
|
93
91
|
[stable-version-badge]: https://img.shields.io/pypi/v/r5py?label=Stable
|
|
94
92
|
[stable-version-link]: https://github.com/r5py/r5py/releases
|
|
93
|
+
[test-status-badge]: https://github.com/r5py/r5py/actions/workflows/test.yml/badge.svg
|
|
94
|
+
[test-status-link]: https://github.com/r5py/r5py/actions/workflows/test.yml
|
|
95
95
|
|
|
96
96
|
<!-- (2) other links -->
|
|
97
97
|
[conda-create-env-from-yml]: https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html#creating-an-environment-from-an-environment-yml-file
|
|
@@ -29,9 +29,10 @@ dependencies = [
|
|
|
29
29
|
"requests",
|
|
30
30
|
"scikit-learn",
|
|
31
31
|
"shapely>=2.0",
|
|
32
|
-
"simplification"
|
|
32
|
+
"simplification",
|
|
33
|
+
"typing_extensions; python_version < '3.13'"
|
|
33
34
|
]
|
|
34
|
-
requires-python = ">=3.
|
|
35
|
+
requires-python = ">=3.10"
|
|
35
36
|
|
|
36
37
|
classifiers = [
|
|
37
38
|
"Programming Language :: Python :: 3",
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
"""R5 classes."""
|
|
4
4
|
|
|
5
5
|
from .access_leg import AccessLeg
|
|
6
|
-
from .breakdown_stat import BreakdownStat
|
|
7
6
|
from .detailed_itineraries import DetailedItineraries, DetailedItinerariesComputer
|
|
8
7
|
from .direct_leg import DirectLeg
|
|
9
8
|
from .egress_leg import EgressLeg
|
|
@@ -21,7 +20,6 @@ from .trip_planner import TripPlanner
|
|
|
21
20
|
|
|
22
21
|
__all__ = [
|
|
23
22
|
"AccessLeg",
|
|
24
|
-
"BreakdownStat",
|
|
25
23
|
"DetailedItineraries",
|
|
26
24
|
"DetailedItinerariesComputer",
|
|
27
25
|
"DirectLeg",
|
|
@@ -45,7 +45,6 @@ class RegionalTask:
|
|
|
45
45
|
speed_cycling=12.0,
|
|
46
46
|
max_public_transport_rides=8,
|
|
47
47
|
max_bicycle_traffic_stress=3,
|
|
48
|
-
breakdown=False,
|
|
49
48
|
):
|
|
50
49
|
"""
|
|
51
50
|
Create a RegionalTask, a computing request for R5.
|
|
@@ -110,8 +109,6 @@ class RegionalTask:
|
|
|
110
109
|
max_bicycle_traffic_stress : int
|
|
111
110
|
Maximum stress level for cyclist routing, ranges from 1-4 see
|
|
112
111
|
https://docs.conveyal.com/learn-more/traffic-stress Default: 3
|
|
113
|
-
breakdown : bool
|
|
114
|
-
Compute a more detailed breakdown of the routes. Default: False
|
|
115
112
|
"""
|
|
116
113
|
self._regional_task = com.conveyal.r5.analyst.cluster.RegionalTask()
|
|
117
114
|
self.scenario = Scenario()
|
|
@@ -149,8 +146,6 @@ class RegionalTask:
|
|
|
149
146
|
|
|
150
147
|
# always record travel times
|
|
151
148
|
self._regional_task.recordTimes = True
|
|
152
|
-
# also report paths, if `breakdown`
|
|
153
|
-
self.breakdown = breakdown
|
|
154
149
|
|
|
155
150
|
# a few settings we don’t expose (yet?)
|
|
156
151
|
self._regional_task.makeTauiSite = False
|
|
@@ -185,32 +180,6 @@ class RegionalTask:
|
|
|
185
180
|
access_modes, com.conveyal.r5.api.util.LegMode
|
|
186
181
|
)
|
|
187
182
|
|
|
188
|
-
@property
|
|
189
|
-
def breakdown(self):
|
|
190
|
-
"""Compute a more detailed breakdown of the routes."""
|
|
191
|
-
return self._breakdown
|
|
192
|
-
|
|
193
|
-
@breakdown.setter
|
|
194
|
-
def breakdown(self, breakdown):
|
|
195
|
-
self._breakdown = breakdown
|
|
196
|
-
self._regional_task.includePathResults = breakdown
|
|
197
|
-
|
|
198
|
-
# R5 has a maximum number of destinations for which it returns detailed
|
|
199
|
-
# information, and it’s set to 5000 by default.
|
|
200
|
-
# The value is a static property of com.conveyal.r5.analyst.cluster.PathResult;
|
|
201
|
-
# static properites of Java classes can be modified in a singleton kind of way
|
|
202
|
-
try:
|
|
203
|
-
num_destinations = len(self.destinations)
|
|
204
|
-
except AttributeError:
|
|
205
|
-
num_destinations = 0
|
|
206
|
-
if (
|
|
207
|
-
num_destinations
|
|
208
|
-
> com.conveyal.r5.analyst.cluster.PathResult.MAX_PATH_DESTINATIONS
|
|
209
|
-
):
|
|
210
|
-
com.conveyal.r5.analyst.cluster.PathResult.MAX_PATH_DESTINATIONS = (
|
|
211
|
-
num_destinations + 1
|
|
212
|
-
)
|
|
213
|
-
|
|
214
183
|
@property
|
|
215
184
|
def departure(self):
|
|
216
185
|
"""Find public transport connections leaving within ``departure_time_window`` after ``departure`` (datetime.datetime)."""
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.2
|
|
2
2
|
Name: r5py
|
|
3
|
-
Version: 1.0.
|
|
3
|
+
Version: 1.0.2
|
|
4
4
|
Summary: Python wrapper for the R5 routing analysis engine
|
|
5
5
|
Author: Christoph Fink, Willem Klumpenhouwer, Marcus Sairava, Rafael Pereira, Henrikki Tenkanen
|
|
6
6
|
License: GPL-3.0-or-later or MIT
|
|
@@ -13,7 +13,7 @@ Classifier: Programming Language :: Python :: 3
|
|
|
13
13
|
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
|
|
14
14
|
Classifier: License :: OSI Approved :: MIT License
|
|
15
15
|
Classifier: Operating System :: OS Independent
|
|
16
|
-
Requires-Python: >=3.
|
|
16
|
+
Requires-Python: >=3.10
|
|
17
17
|
Description-Content-Type: text/markdown
|
|
18
18
|
License-File: LICENSE
|
|
19
19
|
Requires-Dist: ConfigArgParse
|
|
@@ -30,6 +30,7 @@ Requires-Dist: requests
|
|
|
30
30
|
Requires-Dist: scikit-learn
|
|
31
31
|
Requires-Dist: shapely>=2.0
|
|
32
32
|
Requires-Dist: simplification
|
|
33
|
+
Requires-Dist: typing_extensions; python_version < "3.13"
|
|
33
34
|
Provides-Extra: docs
|
|
34
35
|
Requires-Dist: contextily; extra == "docs"
|
|
35
36
|
Requires-Dist: folium; extra == "docs"
|
|
@@ -70,7 +71,7 @@ Requires-Dist: typing-extensions; extra == "tests"
|
|
|
70
71
|
[![downloads (pypi)][downloads-pypi-badge]][downloads-pypi-link]
|
|
71
72
|
[![downloads (conda-forge)][downloads-conda-forge-badge]][downloads-conda-forge-link]
|
|
72
73
|
<br />
|
|
73
|
-
[![
|
|
74
|
+
[![Unit tests][test-status-badge]][test-status-link]
|
|
74
75
|
[![Documentation Status][rtd-status-badge]][rtd-status-link]
|
|
75
76
|
[![Coverage][coverage-badge]][coverage-link]
|
|
76
77
|
<br />
|
|
@@ -137,9 +138,7 @@ your project better.
|
|
|
137
138
|
|
|
138
139
|
<!-- (1) badges -->
|
|
139
140
|
[binder-badge]: https://img.shields.io/badge/Try%20r5py%20with-binder-F5A252.svg?logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAFkAAABZCAMAAABi1XidAAAB8lBMVEX///9XmsrmZYH1olJXmsr1olJXmsrmZYH1olJXmsr1olJXmsrmZYH1olL1olJXmsr1olJXmsrmZYH1olL1olJXmsrmZYH1olJXmsr1olL1olJXmsrmZYH1olL1olJXmsrmZYH1olL1olL0nFf1olJXmsrmZYH1olJXmsq8dZb1olJXmsrmZYH1olJXmspXmspXmsr1olL1olJXmsrmZYH1olJXmsr1olL1olJXmsrmZYH1olL1olLeaIVXmsrmZYH1olL1olL1olJXmsrmZYH1olLna31Xmsr1olJXmsr1olJXmsrmZYH1olLqoVr1olJXmsr1olJXmsrmZYH1olL1olKkfaPobXvviGabgadXmsqThKuofKHmZ4Dobnr1olJXmsr1olJXmspXmsr1olJXmsrfZ4TuhWn1olL1olJXmsqBi7X1olJXmspZmslbmMhbmsdemsVfl8ZgmsNim8Jpk8F0m7R4m7F5nLB6jbh7jbiDirOEibOGnKaMhq+PnaCVg6qWg6qegKaff6WhnpKofKGtnomxeZy3noG6dZi+n3vCcpPDcpPGn3bLb4/Mb47UbIrVa4rYoGjdaIbeaIXhoWHmZYHobXvpcHjqdH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cVNuUDIndpDbdsfrqsOppeXl5Y+XVKdjFCTh+zGaVuj0d9zy05PPK3QzBamxdwtTCrzyg/2Rvf2EstUjordGwa/kx9mSJLr8mLLtCW8HHGJc2R5hS219IiF6PnTusOqcMl57gm0Z8kanKMAQg0qSyuZfn7zItsbGyO9QlnxY0eCuD1XL2ys/MsrQhltE7Ug0uFOzufJFE2PxBo/YAx8XPPdDwWN0MrDRYIZF0mSMKCNHgaIVFoBbNoLJ7tEQDKxGF0kcLQimojCZopv0OkNOyWCCg9XMVAi7ARJzQdM2QUh0gmBozjc3Skg6dSBRqDGYSUOu66Zg+I2fNZs/M3/f/Grl/XnyF1Gw3VKCez0PN5IUfFLqvgUN4C0qNqYs5YhPL+aVZYDE4IpUk57oSFnJm4FyCqqOE0jhY2SMyLFoo56zyo6becOS5UVDdj7Vih0zp+tcMhwRpBeLyqtIjlJKAIZSbI8SGSF3k0pA3mR5tHuwPFoa7N7reoq2bqCsAk1HqCu5uvI1n6JuRXI+S1Mco54YmYTwcn6Aeic+kssXi8XpXC4V3t7/ADuTNKaQJdScAAAAAElFTkSuQmCC
|
|
140
|
-
[binder-link]: https://
|
|
141
|
-
[build-status-badge]: https://github.com/r5py/r5py/actions/workflows/build-merged-pull-requests.yml/badge.svg
|
|
142
|
-
[build-status-link]: https://github.com/r5py/r5py/actions/workflows/build-merged-pull-requests.yml
|
|
141
|
+
[binder-link]: https://mybinder.org/v2/gh/r5py/r5py/stable?urlpath=tree/docs/user-guide/user-manual/quickstart.md
|
|
143
142
|
[coverage-badge]: https://codecov.io/gh/r5py/r5py/branch/main/graph/badge.svg?token=WG8RBMZBK6
|
|
144
143
|
[coverage-link]: https://codecov.io/gh/r5py/r5py
|
|
145
144
|
[doi-badge]: https://zenodo.org/badge/DOI/10.5281/zenodo.7060437.svg
|
|
@@ -152,6 +151,8 @@ your project better.
|
|
|
152
151
|
[rtd-status-link]: https://r5py.readthedocs.io/
|
|
153
152
|
[stable-version-badge]: https://img.shields.io/pypi/v/r5py?label=Stable
|
|
154
153
|
[stable-version-link]: https://github.com/r5py/r5py/releases
|
|
154
|
+
[test-status-badge]: https://github.com/r5py/r5py/actions/workflows/test.yml/badge.svg
|
|
155
|
+
[test-status-link]: https://github.com/r5py/r5py/actions/workflows/test.yml
|
|
155
156
|
|
|
156
157
|
<!-- (2) other links -->
|
|
157
158
|
[conda-create-env-from-yml]: https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html#creating-an-environment-from-an-environment-yml-file
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
LICENSE
|
|
2
|
+
MANIFEST.in
|
|
2
3
|
README.md
|
|
3
4
|
pyproject.toml
|
|
4
5
|
src/r5py/__init__.py
|
|
@@ -11,7 +12,6 @@ src/r5py.egg-info/top_level.txt
|
|
|
11
12
|
src/r5py/r5/__init__.py
|
|
12
13
|
src/r5py/r5/access_leg.py
|
|
13
14
|
src/r5py/r5/base_travel_time_matrix.py
|
|
14
|
-
src/r5py/r5/breakdown_stat.py
|
|
15
15
|
src/r5py/r5/detailed_itineraries.py
|
|
16
16
|
src/r5py/r5/direct_leg.py
|
|
17
17
|
src/r5py/r5/egress_leg.py
|
|
@@ -48,7 +48,9 @@ src/r5py/util/spatially_clustered_geodataframe.py
|
|
|
48
48
|
src/r5py/util/validating_requests_session.py
|
|
49
49
|
src/r5py/util/warnings.py
|
|
50
50
|
src/r5py/util/working_copy.py
|
|
51
|
-
tests/
|
|
51
|
+
tests/__init__.py
|
|
52
|
+
tests/conftest.py
|
|
53
|
+
tests/temporary_directory.py
|
|
52
54
|
tests/test_camel_to_snake_case.py
|
|
53
55
|
tests/test_classpath.py
|
|
54
56
|
tests/test_config.py
|
|
@@ -75,4 +77,39 @@ tests/test_trip_leg.py
|
|
|
75
77
|
tests/test_trip_planner.py
|
|
76
78
|
tests/test_validating_request_session.py
|
|
77
79
|
tests/test_verbose_warnings.py
|
|
78
|
-
tests/test_working_directory.py
|
|
80
|
+
tests/test_working_directory.py
|
|
81
|
+
tests/conftest_d/__init__.py
|
|
82
|
+
tests/conftest_d/data_directory.py
|
|
83
|
+
tests/conftest_d/destinations.py
|
|
84
|
+
tests/conftest_d/file_digest.py
|
|
85
|
+
tests/conftest_d/garbage_collection.py
|
|
86
|
+
tests/conftest_d/origins.py
|
|
87
|
+
tests/conftest_d/r5_jar.py
|
|
88
|
+
tests/conftest_d/routing_parameters.py
|
|
89
|
+
tests/conftest_d/routing_results.py
|
|
90
|
+
tests/conftest_d/sample_data.py
|
|
91
|
+
tests/conftest_d/transport_network.py
|
|
92
|
+
tests/conftest_d/upstream_r5.py
|
|
93
|
+
tests/data/test_detailed_itineraries_bicycle.gpkg.zip
|
|
94
|
+
tests/data/test_detailed_itineraries_car.gpkg.zip
|
|
95
|
+
tests/data/test_detailed_itineraries_transit.gpkg.zip
|
|
96
|
+
tests/data/test_detailed_itineraries_walk.gpkg.zip
|
|
97
|
+
tests/data/test_invalid_points_duplicate_ids.geojson
|
|
98
|
+
tests/data/test_invalid_points_no_id_column.geojson
|
|
99
|
+
tests/data/test_isochrones_bicycle.gpkg.zip
|
|
100
|
+
tests/data/test_isochrones_car.gpkg.zip
|
|
101
|
+
tests/data/test_isochrones_from_multiple_origins.gpkg.zip
|
|
102
|
+
tests/data/test_isochrones_transit.gpkg.zip
|
|
103
|
+
tests/data/test_isochrones_walk.gpkg.zip
|
|
104
|
+
tests/data/test_multiple_origins.geojson
|
|
105
|
+
tests/data/test_snapped_population_grid_centroids.geojson
|
|
106
|
+
tests/data/test_travel_times_bicycle.csv
|
|
107
|
+
tests/data/test_travel_times_car.csv
|
|
108
|
+
tests/data/test_travel_times_transit.csv
|
|
109
|
+
tests/data/test_travel_times_walk.csv
|
|
110
|
+
tests/data/test_valid_points_data.geojson
|
|
111
|
+
tests/data/test_valid_single_point_data.geojson
|
|
112
|
+
tests/data/test_walking_details_not_snapped.csv
|
|
113
|
+
tests/data/test_walking_details_snapped.csv
|
|
114
|
+
tests/data/test_walking_times_not_snapped.csv
|
|
115
|
+
tests/data/test_walking_times_snapped.csv
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
|
|
3
|
+
"""Configuration and fixtures for testing r5py."""
|
|
4
|
+
|
|
5
|
+
# This is a init file common to all tests. It is automatically sourced
|
|
6
|
+
# by pytest et al.
|
|
7
|
+
|
|
8
|
+
# This file imports all files in the conftest.d directory
|
|
9
|
+
|
|
10
|
+
# Define common constants (e.g., paths to test data) and fixtures (e.g.,
|
|
11
|
+
# transport network) there and import the fixtures into conftest_d/__init__.py.
|
|
12
|
+
|
|
13
|
+
from .conftest_d import * # noqa: F401,F403
|
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
"""Fixtures to be used in r5py tests."""
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
from .destinations import (
|
|
8
|
+
population_grid,
|
|
9
|
+
population_grid_points,
|
|
10
|
+
population_grid_points_first_three,
|
|
11
|
+
population_grid_points_second_three,
|
|
12
|
+
population_grid_points_four,
|
|
13
|
+
snapped_population_grid_points,
|
|
14
|
+
unreachable_stops,
|
|
15
|
+
unsnappable_points,
|
|
16
|
+
)
|
|
17
|
+
|
|
18
|
+
from .file_digest import (
|
|
19
|
+
file_digest_test_file_as_pathlib_path,
|
|
20
|
+
file_digest_test_file_as_str,
|
|
21
|
+
file_digest_sha256,
|
|
22
|
+
file_digest_blake2b,
|
|
23
|
+
file_digest_blake2s,
|
|
24
|
+
)
|
|
25
|
+
|
|
26
|
+
from .garbage_collection import java_garbage_collection
|
|
27
|
+
|
|
28
|
+
from .origins import (
|
|
29
|
+
multiple_origins,
|
|
30
|
+
origin_point,
|
|
31
|
+
origins_invalid_duplicate_ids,
|
|
32
|
+
origins_invalid_no_id,
|
|
33
|
+
origins_valid_ids,
|
|
34
|
+
)
|
|
35
|
+
|
|
36
|
+
from .r5_jar import (
|
|
37
|
+
r5_jar_cached,
|
|
38
|
+
r5_jar_cached_invalid,
|
|
39
|
+
r5_jar_sha256,
|
|
40
|
+
r5_jar_sha256_github_error_message_when_posting,
|
|
41
|
+
r5_jar_sha256_invalid,
|
|
42
|
+
r5_jar_url,
|
|
43
|
+
)
|
|
44
|
+
|
|
45
|
+
from .routing_parameters import (
|
|
46
|
+
departure_datetime,
|
|
47
|
+
regional_task,
|
|
48
|
+
)
|
|
49
|
+
|
|
50
|
+
from .routing_results import (
|
|
51
|
+
detailed_itineraries_bicycle,
|
|
52
|
+
detailed_itineraries_car,
|
|
53
|
+
detailed_itineraries_transit,
|
|
54
|
+
detailed_itineraries_walk,
|
|
55
|
+
isochrones_from_multiple_origins,
|
|
56
|
+
isochrones_bicycle,
|
|
57
|
+
isochrones_car,
|
|
58
|
+
isochrones_transit,
|
|
59
|
+
isochrones_walk,
|
|
60
|
+
travel_times_bicycle,
|
|
61
|
+
travel_times_car,
|
|
62
|
+
travel_times_transit,
|
|
63
|
+
travel_times_walk,
|
|
64
|
+
walking_details_not_snapped,
|
|
65
|
+
walking_details_snapped,
|
|
66
|
+
walking_times_not_snapped,
|
|
67
|
+
walking_times_snapped,
|
|
68
|
+
)
|
|
69
|
+
|
|
70
|
+
from .sample_data import (
|
|
71
|
+
sample_data_set_sha256,
|
|
72
|
+
sample_data_set_url,
|
|
73
|
+
)
|
|
74
|
+
|
|
75
|
+
from .transport_network import (
|
|
76
|
+
gtfs_file_path,
|
|
77
|
+
gtfs_timezone_helsinki,
|
|
78
|
+
not_a_gtfs_file,
|
|
79
|
+
osm_pbf_file_path,
|
|
80
|
+
transport_network,
|
|
81
|
+
transport_network_files_tuple,
|
|
82
|
+
transport_network_from_test_directory,
|
|
83
|
+
transport_network_from_test_files,
|
|
84
|
+
transport_network_from_test_files_without_gtfs,
|
|
85
|
+
)
|
|
86
|
+
|
|
87
|
+
from .upstream_r5 import (
|
|
88
|
+
can_compute_detailed_route_geometries,
|
|
89
|
+
)
|
|
90
|
+
|
|
91
|
+
__all__ = [
|
|
92
|
+
"can_compute_detailed_route_geometries",
|
|
93
|
+
"departure_datetime",
|
|
94
|
+
"detailed_itineraries_bicycle",
|
|
95
|
+
"detailed_itineraries_car",
|
|
96
|
+
"detailed_itineraries_transit",
|
|
97
|
+
"detailed_itineraries_walk",
|
|
98
|
+
"file_digest_test_file_as_pathlib_path",
|
|
99
|
+
"file_digest_test_file_as_str",
|
|
100
|
+
"file_digest_sha256",
|
|
101
|
+
"file_digest_blake2b",
|
|
102
|
+
"file_digest_blake2s",
|
|
103
|
+
"java_garbage_collection",
|
|
104
|
+
"gtfs_file_path",
|
|
105
|
+
"gtfs_timezone_helsinki",
|
|
106
|
+
"isochrones_from_multiple_origins",
|
|
107
|
+
"isochrones_bicycle",
|
|
108
|
+
"isochrones_car",
|
|
109
|
+
"isochrones_transit",
|
|
110
|
+
"isochrones_walk",
|
|
111
|
+
"multiple_origins",
|
|
112
|
+
"not_a_gtfs_file",
|
|
113
|
+
"origin_point",
|
|
114
|
+
"origins_invalid_duplicate_ids",
|
|
115
|
+
"origins_invalid_no_id",
|
|
116
|
+
"origins_valid_ids",
|
|
117
|
+
"osm_pbf_file_path",
|
|
118
|
+
"population_grid",
|
|
119
|
+
"population_grid_points",
|
|
120
|
+
"population_grid_points_first_three",
|
|
121
|
+
"population_grid_points_four",
|
|
122
|
+
"population_grid_points_second_three",
|
|
123
|
+
"regional_task",
|
|
124
|
+
"r5_jar_cached",
|
|
125
|
+
"r5_jar_cached_invalid",
|
|
126
|
+
"r5_jar_sha256",
|
|
127
|
+
"r5_jar_sha256_github_error_message_when_posting",
|
|
128
|
+
"r5_jar_sha256_invalid",
|
|
129
|
+
"r5_jar_url",
|
|
130
|
+
"sample_data_set_sha256",
|
|
131
|
+
"sample_data_set_url",
|
|
132
|
+
"snapped_population_grid_points",
|
|
133
|
+
"transport_network",
|
|
134
|
+
"transport_network_files_tuple",
|
|
135
|
+
"transport_network_from_test_directory",
|
|
136
|
+
"transport_network_from_test_files",
|
|
137
|
+
"transport_network_from_test_files_without_gtfs",
|
|
138
|
+
"travel_times_bicycle",
|
|
139
|
+
"travel_times_car",
|
|
140
|
+
"travel_times_transit",
|
|
141
|
+
"travel_times_walk",
|
|
142
|
+
"unreachable_stops",
|
|
143
|
+
"unsnappable_points",
|
|
144
|
+
"walking_details_not_snapped",
|
|
145
|
+
"walking_details_snapped",
|
|
146
|
+
"walking_times_not_snapped",
|
|
147
|
+
"walking_times_snapped",
|
|
148
|
+
]
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
"""Fixtures related to the destinations used in routing."""
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
import geopandas
|
|
8
|
+
import pytest
|
|
9
|
+
import shapely
|
|
10
|
+
|
|
11
|
+
from .data_directory import DATA_DIRECTORY
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
SNAPPED_POPULATION_GRID_POINTS = (
|
|
15
|
+
DATA_DIRECTORY / "test_snapped_population_grid_centroids.geojson"
|
|
16
|
+
)
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
@pytest.fixture(scope="session")
|
|
20
|
+
def population_grid():
|
|
21
|
+
"""Load the grid point data set."""
|
|
22
|
+
import r5py.sampledata.helsinki
|
|
23
|
+
|
|
24
|
+
yield geopandas.read_file(r5py.sampledata.helsinki.population_grid)
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
@pytest.fixture(scope="session")
|
|
28
|
+
def population_grid_points(population_grid):
|
|
29
|
+
"""Return the grid point data set in EPSG:4326."""
|
|
30
|
+
population_grid_points = population_grid.copy()
|
|
31
|
+
population_grid_points.geometry = population_grid_points.geometry.to_crs(
|
|
32
|
+
"EPSG:3067"
|
|
33
|
+
).centroid.to_crs("EPSG:4326")
|
|
34
|
+
yield population_grid_points
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
@pytest.fixture(scope="session")
|
|
38
|
+
def population_grid_points_first_three(population_grid_points):
|
|
39
|
+
"""Return the first set of three grid points."""
|
|
40
|
+
yield population_grid_points[0:3]
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
@pytest.fixture(scope="session")
|
|
44
|
+
def population_grid_points_second_three(population_grid_points):
|
|
45
|
+
"""Return the second set of three grid points."""
|
|
46
|
+
yield population_grid_points[4:7]
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
@pytest.fixture(scope="session")
|
|
50
|
+
def population_grid_points_four(population_grid_points):
|
|
51
|
+
"""Return four grid points."""
|
|
52
|
+
yield population_grid_points[10:14]
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
@pytest.fixture(scope="session")
|
|
56
|
+
def snapped_population_grid_points():
|
|
57
|
+
"""Return a `geopandas.GeoDataFrame` that contains grid points snapped to the street network."""
|
|
58
|
+
yield geopandas.read_file(SNAPPED_POPULATION_GRID_POINTS)
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
@pytest.fixture
|
|
62
|
+
def unreachable_stops():
|
|
63
|
+
"""Return a list of public transport stops that cannot be reached."""
|
|
64
|
+
yield [
|
|
65
|
+
1294132,
|
|
66
|
+
1174101,
|
|
67
|
+
1452601,
|
|
68
|
+
]
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
@pytest.fixture
|
|
72
|
+
def unsnappable_points():
|
|
73
|
+
"""Retrieve a set of points that cannot be snapped to the sample data network."""
|
|
74
|
+
yield geopandas.GeoDataFrame(
|
|
75
|
+
{
|
|
76
|
+
"id": [1, 2],
|
|
77
|
+
"geometry": [
|
|
78
|
+
shapely.Point(48.20, 16.36), # far away from Helsinki
|
|
79
|
+
shapely.Point(-0.22, -78.51), # even further
|
|
80
|
+
],
|
|
81
|
+
},
|
|
82
|
+
crs="EPSG:4326",
|
|
83
|
+
)
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
"""Fixtures describing the expected routing results."""
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
import pytest
|
|
8
|
+
|
|
9
|
+
from .routing_results import ISOCHRONES_WALK
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
ISOCHRONES_WALK_BLAKE2B = "5e91181cfdff18a3ebcf289eba1955b61b27260fa40d1cd669bb2f754c31b23b59ecd74ee9d3a31f2d51c9de32aff0781ff5c948eb4ea220b622525d94e6a625"
|
|
13
|
+
ISOCHRONES_WALK_BLAKE2S = (
|
|
14
|
+
"da098b9fcf440e7252b2b213160dd810392c03ee07c58ababfddf7d4c5d8d502"
|
|
15
|
+
)
|
|
16
|
+
ISOCHRONES_WALK_SHA256 = (
|
|
17
|
+
"2a444c35ef676928d2a70914c64e34c569b10a6473ee6d61c74d9740351d80cc"
|
|
18
|
+
)
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
@pytest.fixture
|
|
22
|
+
def file_digest_test_file_as_pathlib_path():
|
|
23
|
+
"""Return the path of a test file as a pathlib.Path."""
|
|
24
|
+
yield ISOCHRONES_WALK
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
@pytest.fixture
|
|
28
|
+
def file_digest_test_file_as_str(file_digest_test_file_as_pathlib_path):
|
|
29
|
+
"""Return the path of a test file as a str."""
|
|
30
|
+
yield f"{file_digest_test_file_as_pathlib_path}"
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
@pytest.fixture()
|
|
34
|
+
def file_digest_sha256():
|
|
35
|
+
"""Return the expected SHA256 hash for the test file."""
|
|
36
|
+
yield ISOCHRONES_WALK_SHA256
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
@pytest.fixture()
|
|
40
|
+
def file_digest_blake2b():
|
|
41
|
+
"""Return the expected BLAKE2B hash for the test file."""
|
|
42
|
+
yield ISOCHRONES_WALK_BLAKE2B
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
@pytest.fixture()
|
|
46
|
+
def file_digest_blake2s():
|
|
47
|
+
"""Return the expected BLAKE2S hash for the test file."""
|
|
48
|
+
yield ISOCHRONES_WALK_BLAKE2S
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
"""An auto-use fixture that calls Java garbage collection before every function."""
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
import jpype
|
|
8
|
+
import pytest
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
@pytest.fixture(autouse=True, scope="function")
|
|
12
|
+
def java_garbage_collection():
|
|
13
|
+
"""Call Java GC before every function."""
|
|
14
|
+
jpype.java.lang.System.gc()
|