centrality

Low-level internals. These are the Rust-backed structures and functions that power cityseer. They carry no stability guarantee and are subject to breaking changes from time to time. Users are encouraged to use the higher-level wrappers instead, which are more stable: the CityNetwork class, or the metrics and tools modules. The basic information below is provided for those who do wish to work with the lower-level internals.

Centrality analysis utilities for network structures.

CentralityResult

CentralityResult

CentralityResult
( )

metrics

OdMatrix

Sparse origin-destination weight matrix for OD-weighted centrality. Stores per-pair trip weights in a nested HashMap for O(1) lookup. Constructed once and passed to centrality functions; can be reused across calls.

OdMatrix

OdMatrix
( )

len

len
(
self
/
)

Number of non-zero OD pairs.

n_origins

n_origins
(
self
/
)

Number of unique origin nodes.