Skip to main content

Python library for transport indicator analysis based on travel-time matrices.

Project description

Documentation Status PythonVersion Black

Transport Frames is a Python library designed for spatial transport analysis, offering tools to:

  • Generate transport frames based on drive graphs.

  • Identify priority roads by evaluating the expected popularity of routes between exit pairs.

  • Update drive graphs with new road connections, ensuring proper integration.

  • Grade territory polygons by analyzing distances to federal and regional roads.

  • Compute a weighted connectivity score for a region based on accessibility to transport services and road network quality.

  • Interpret accessibility scores into textual descriptions.

  • Aggregate administrative-level statistics by computing transport indicators at different spatial scales (regions, districts, etc.).

  • Analyze territory-specific indicators by using buffer-based calculations around the center of a given territory.

Features

Frame and Road Network Analysis

  • Constructs frames from drive graphs to analyze road connectivity.

  • Investigates priority roads based on estimated route popularity.

  • Updates transport graphs by adding new edges and ensuring seamless network connectivity.

Territory Grading and Connectivity

  • Grades territories based on proximity to federal and regional roads.

  • Computes connectivity values from road networks and accessibility to key transport services (bus stops, railways, airports, ports).

  • Assigns territory-wide scores to summarize transport accessibility.

Indicator Computation

The library calculates various transport indicators at different administrative levels (region, district, etc.), including:

  • Distance to regional centers

  • Distance to federal roads

  • Connectivity score (measuring how well a region is connected to the transport network)

  • Lengths of roads and railway paths

  • Road density (road length per area)

  • Service accessibility (bus routes, railway coverage, and general service accessibility)

  • Number of services (number of services inside or near a given territory)

  • Number of bus routes (number of bus routes intersecting the territory)

  • Distance to nature objects (water objects, nature reserves, etc.)

Installation

Transport_frames can be installed with pip:

pip install transport-frames

How to use

For the detailed tutorial on usage case see our examples.

The following Jupyter Notebooks illustrate core library functions:

  1. Graph Frame Creation1_graph_frame_creation.ipynb - Created graph from territory polygon. - Generates transport frames from drive graphs. - Identifies priority roads using network analysis.

  2. Indicator Computation2_indicators.ipynb - Computes transport indicators (road density, connectivity, admin center distances, etc.). - Aggregates statistics at area and territory levels.

  3. Territory grading3_criteria.ipynb - Assigns territory scores based on federal and regional roads accessibility. - Analyzes proximity to key infrastructure (bus stops, ports, airports). - Analyzes connectivity metrics of the territory. - Converts numeric scores into textual interpretations.

  4. Road Graph Updates4_road_adder.ipynb - Updates transport graphs with new roads and edges. - Analyzes connectivity improvement after graph modifications.

  5. Transport Provision5_transport_provision.ipynb - Calculates a transport provision index for each territory polygon. - Combines road and railway density, airport accessibility, and settlement area share into one metric.

Data

Before running the examples, one can use the data from examples/data directory. You can use your own data, but it must follow the structure described in the API documentation.

Documentation

Detailed information and description of Transport Frames is available in documentation.

Project Structure

The latest version of the library is available in the main branch.

The repository includes the following directories and modules:

  • transport_frames - directory with the library code:

    • graph - graph creation module

    • frame - creation of the frame and priority roads module

    • criteria - module for grading territory based on frame and criteria calculation

    • indicators - module for area and territory indicators calculation

    • road_adder - module for updating graph with new road edges

    • utils - module containing utulity functions and consts

  • tests pytest testing

  • examples examples of how methods work

  • docs - documentation sources

License

The project has BSD-3-Clause license

Contacts

You can contact us:

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

transport_frames-2.0.6.tar.gz (38.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

transport_frames-2.0.6-py3-none-any.whl (37.6 kB view details)

Uploaded Python 3

File details

Details for the file transport_frames-2.0.6.tar.gz.

File metadata

  • Download URL: transport_frames-2.0.6.tar.gz
  • Upload date:
  • Size: 38.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for transport_frames-2.0.6.tar.gz
Algorithm Hash digest
SHA256 eb76b761843fa59010f65e2e7d67e9dd0977d7f8a32762b0a073bb1ab3db742c
MD5 76912f33eb96b1bc29d8ac2baa4fc2a9
BLAKE2b-256 1b3772964bf8e28d567d7bfcf8e7de90b1f0263eb9b2b8b0a177156705c43d9f

See more details on using hashes here.

File details

Details for the file transport_frames-2.0.6-py3-none-any.whl.

File metadata

File hashes

Hashes for transport_frames-2.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 816742483c8360121d26d5808bdfe2168b3696fa031f66e823f5de08015a2386
MD5 0f67740ce5772dcf0820bbcb25cac862
BLAKE2b-256 b259c7402603914594d84c045655f23c3c634d01b7bfc4f24feb7b2de59a44be

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page