class RoadNetwork(dtcc.Object)[source]

Public members

property linestrings : list[LineString]
property multilinestrings : MultiLineString
property bounds

Return BOUNDS geometry.

to_shapely()[source]
to_proto()[source]

Return a protobuf representation of the Object.

from_proto(pb)[source]

Initialize Object from a protobuf representation.

RoadNetwork(id: str = <factory>, attributes: dict = <factory>, ...)

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

__repr__()

Return repr(self).

__eq__(other)

Return self==value.

to_df(crs=None)
to_matrix(bidirectional=True) csr_matrix
to_surfaces(width_attribute='', ...)
view()

View a roadnetwork in 3D with a GLFW window.

vertices : ndarray
edges : ndarray
length : ndarray
property num_children

Return number of child objects.

property lod0

Return LOD0 geometry.

property lod1

Return LOD0 geometry.

property lod2

Return LOD0 geometry.

property lod3

Return LOD0 geometry.

property mesh

Return LOD0 geometry.

property volume_mesh

Return LOD0 geometry.

property point_cloud

Return POINT_CLOUD geometry.

property raster

Return RASTER geometry.

add_child(child)[source]

Add child object.

add_children(children)[source]

Adds a list of children objects.

add_geometry(geometry: Geometry, geometry_type: GeometryType | str)[source]

Add geometry to object.

add_field(field, geometry_type)[source]

Add a field to a geometry of the object.

get_children(child_type)[source]
set_child_attributues(child_type, attribute, values)[source]
get_child_attributes(child_type, attribute, default=None)[source]
flatten_geometry(geom_type: GeometryType)[source]

Returns a single geometry of the specified type, merging all the geometries of the children.

calculate_bounds(lod=None)[source]

Calculate the bounding box of the object.

defined_geometries()[source]

Return a list of the types of geometries defined on this object.

defined_attributes()[source]

Return a list of the attributes defined on this object.

id : str
attributes : dict
children : dict
geometry : dict
to_json() str

Return a JSON representation of the object.

copy(**kwargs)

Return a copy of the object.

classmethod add_methods(module, name=None)

Adds methods from a module or function to the class.

classmethod print_methods(verbose=False)

Print the methods that have been added to the class.