aequilibrae.paths.TrafficClass#

class aequilibrae.paths.TrafficClass(name: str, graph: Graph, matrix: AequilibraeMatrix)[source]#

Traffic class for equilibrium traffic assignment

>>> from aequilibrae import Project
>>> from aequilibrae.matrix import AequilibraeMatrix
>>> from aequilibrae.paths import TrafficClass

>>> project = Project.from_path("/tmp/test_project")
>>> project.network.build_graphs()

>>> graph = project.network.graphs['c'] # we grab the graph for cars
>>> graph.set_graph('free_flow_time') # let's say we want to minimize time
>>> graph.set_skimming(['free_flow_time', 'distance']) # And will skim time and distance
>>> graph.set_blocked_centroid_flows(True)

>>> proj_matrices = project.matrices

>>> demand = AequilibraeMatrix()
>>> demand = proj_matrices.get_matrix("demand_omx")
>>> demand.computational_view(['matrix'])

>>> tc = TrafficClass("car", graph, demand)
>>> tc.set_pce(1.3)
__init__(name: str, graph: Graph, matrix: AequilibraeMatrix) None[source]#

Instantiates the class

Arguments:

name (str): UNIQUE class name.

graph (Graph): Class/mode-specific graph

matrix (AequilibraeMatrix): Class/mode-specific matrix. Supports multiple user classes

Methods

__init__(name, graph, matrix)

Instantiates the class

set_fixed_cost(field_name[, multiplier])

Sets value of time

set_pce(pce)

Sets Passenger Car equivalent

set_select_links(links)

Set the selected links.

set_vot(value_of_time)

Sets value of time

Attributes

info