6.1.3.3.4. aequilibrae.project.network.Node

class aequilibrae.project.network.Node(dataset)

Bases: aequilibrae.project.network.safe_class.SafeClass

A Node object represents a single record in the nodes table

from aequilibrae import Project
from shapely.geometry import Point

proj = Project()
proj.open('path/to/project/folder')

all_nodes = proj.network.nodes

# We can just get one link in specific
node1 = all_nodes.get(7890)

# We can find out which fields exist for the links
which_fields_do_we_have = node1.data_fields()

# And edit each one like this
node1.comment = 'This node is important'

# It success if the node_id already does not exist
node1.renumber(998877)

node.geometry = Point(1,2)

# We can just save the node
node1.save()
__init__(dataset)

Initialize self. See help(type(self)) for accurate signature.

Methods

__init__(dataset)

Initialize self.

connect_mode(area, mode_id[, link_types, …])

Adds centroid connectors for the desired mode to the network file

data_fields()

lists all data fields for the node, as available in the database

renumber(new_id)

Renumbers the node in the network

save()

Saves node to database

__init__(dataset)

Initialize self. See help(type(self)) for accurate signature.