traffic_assignment

dataset

class CargoTrackSegmentEntity(name: str | None = None, optional: bool | None = None, exclude: Iterable[str] | None = None, override_exclude: Iterable[str] | None = None)

Bases: TrackSegmentEntity

capacity
cargo_allowed
cargo_average_time
cargo_max_speed
property max_speed
class DemandNodeEntity(name: str | None = None, optional: bool | None = None, exclude: Iterable[str] | None = None, override_exclude: Iterable[str] | None = None)

Bases: PointEntity

cargo_demand
passenger_demand
class PassengerTrackSegmentEntity(name: str | None = None, optional: bool | None = None, exclude: Iterable[str] | None = None, override_exclude: Iterable[str] | None = None)

Bases: TrackSegmentEntity

capacity
property max_speed
passenger_average_time
passenger_max_speed
class TrackSegmentEntity(name: str | None = None, optional: bool | None = None, exclude: Iterable[str] | None = None, override_exclude: Iterable[str] | None = None)

Bases: TrafficTransportSegmentEntity

average_time
cargo_flow
passenger_flow
class TrafficTransportSegmentEntity(name: str | None = None, optional: bool | None = None, exclude: Iterable[str] | None = None, override_exclude: Iterable[str] | None = None)

Bases: TransportSegmentEntity

additional_time
average_time
cargo_flow
delay_factor
passenger_car_unit
passenger_flow
volume_to_capacity

model

class CargoTrackModality

Bases: TrackModality

cargo_allowed(model: Model) UniformAttribute | None
get_capacities(model: Model)
get_demands(model: Model) Tuple[ndarray, ndarray]
initialize_parameters(model: Model)
process_capacity(model: Model, init=False) bool
publish_attributes: Sequence[PublishAttribute] = (PublishAttribute(name='cargo_flow', target=None, correction_value=0), PublishAttribute(name='congested_time', target='cargo_average_time', correction_value=1000000000.0))
transport_segment_entity

alias of CargoTrackSegmentEntity

transport_type: str = 'cargo_tracks'
class ModalityStrategy

Bases: object

free_flow_time(model: Model) ndarray
get_capacities(model: Model)
get_demands(model: Model) Tuple[ndarray, ndarray]
initialize_parameters(model: Model)
process_capacity(model: Model, init=False) bool
process_free_flow_time(model: Model, init=False) bool
process_max_speed(model: Model, init=False) bool
publish_attributes: Sequence[PublishAttribute] = (PublishAttribute(name='passenger_flow', target=None, correction_value=0), PublishAttribute(name='cargo_flow', target=None, correction_value=0), PublishAttribute(name='passenger_car_unit', target=None, correction_value=0), PublishAttribute(name='volume_to_capacity', target=None, correction_value=0), PublishAttribute(name='delay_factor', target=None, correction_value=1), PublishAttribute(name='congested_time', target='average_time', correction_value=1000000000.0))
publish_results(model: Model, results: AssignmentResultCollection)
setup_state(model: Model, state: TrackedState, dataset_name: str)
transport_segment_entity

alias of TrafficTransportSegmentEntity

transport_type: str
class Model(model_config: dict, validate_config=True)

Bases: TrackedModel

Calculates traffic attributes on roads

cargo_pcu: float
demand_nodes: t.Optional[ds.DemandNodeEntity] = None
classmethod get_schema_attributes() Iterable[AttributeSpec]
initialize(**_)
modality: ModalityStrategy
project: t.Optional[ProjectWrapper] = None
setup(state: TrackedState, settings: Settings, **_)
shutdown(**_) None
transport_nodes: t.Optional[PointEntity] = None
transport_segments: t.Optional[ds.TrafficTransportSegmentEntity] = None
update(**_) Moment | None
vdf_alpha: t.Union[float, str]
vdf_beta: float
class PassengerTrackModality

Bases: TrackModality

get_demands(model: Model) Tuple[ndarray, ndarray]
publish_attributes: Sequence[PublishAttribute] = (PublishAttribute(name='passenger_flow', target=None, correction_value=0), PublishAttribute(name='congested_time', target='passenger_average_time', correction_value=1000000000.0))
transport_segment_entity

alias of PassengerTrackSegmentEntity

transport_type: str = 'passenger_tracks'
class PublishAttribute(name: 'str', target: 't.Optional[str]' = None, correction_value: 'float' = 0)

Bases: object

correction_value: float = 0
name: str
target: str | None = None
class RoadModality

Bases: ModalityStrategy

transport_type: str = 'roads'
class TrackModality

Bases: ModalityStrategy

initialize_parameters(model: Model)
publish_attributes: Sequence[PublishAttribute] = (PublishAttribute(name='passenger_flow', target=None, correction_value=0), PublishAttribute(name='cargo_flow', target=None, correction_value=0), PublishAttribute(name='congested_time', target='average_time', correction_value=1000000000.0))
transport_segment_entity

alias of TrackSegmentEntity

transport_type: str = 'tracks'
class WaterwayModality

Bases: ModalityStrategy

alpha(model: Model) ndarray

We want waterway segments with locks to have an additional waiting time t_wait We set the free_flow_times of these segments as

t_ff’ = t_ff + t_wait

To convert it to vdf terms:

t_ff’ = t_ff + s’ a = r / t_ff’ b = 4.9

With these aequilibrae can compute: vdf = t_ff’ * (1 + a * volume_over_capacity**b)

free_flow_time(model: Model) ndarray
initialize_parameters(model: Model)
transport_type: str = 'waterways'
convert_v1_v2(config)
get_matrix(csr_array: TrackedCSRArray)