hydromt_delft3dfm.workflows.prepare_1dstructures#

hydromt_delft3dfm.workflows.prepare_1dstructures(branches: ~geopandas.geodataframe.GeoDataFrame, gdf_st: ~geopandas.geodataframe.GeoDataFrame, params: ~pandas.core.frame.DataFrame, st_type: ~typing.Literal['culvert', 'bridge'], id_start: int = 1, filter: str = None, snap_offset: float = 0.0, logger: ~logging.Logger = <Logger hydromt_delft3dfm.workflows.structures (WARNING)>) GeoDataFrame[source]#

Prepare 1D structures from geodataframe.

Include the universal weir (Not Implemented) , culvert and bridge (str_type = ‘bridge’), which can only be used in a single 1D channel.

Structures are first filtered for value specified in filter on the column st_type. They are then snapped to the existing network within a max distance defined in snap_offset and will be dropped if not snapped. Finally, crossections are read and set up for the remaining structures.

Parameters:
  • branches (gpd.GeoDataFrame) – gpd.GeoDataFrame of branches.

  • gdf_st (gpd.GeoDataFrame) – gpd.GeoDataFrame of structures.

  • params (pd.DataFrame) – pd.Dataframe of defaults values for gdf_st.

  • st_type (str) – structure type. Either “culvert” or “bridge”.

  • id_start (int, optional) – Start index for structure id. By default 1.

  • filter (str, optional) – Keyword in structure_type column of gdf_st used to filter features.

  • snap_offset (float, optional) – Snapping tolerance to automatically snapping to branch. By default 0.0, no snapping is applied.

  • logger (logging.Logger, optional) – Logger.

Returns:

Prepared structures with structure_id, structure_type, branchid and chainage.

Return type:

gpd.GeoDataFrame