norman-tom / pyromb

Pyromb is a python package to convert a catchment diagram developed in QGIS, or any GIS package, to a RORB or WBNM control file
MIT License
6 stars 3 forks source link

ID fields are assumed to be unique #7

Open norman-tom opened 1 year ago

norman-tom commented 1 year ago

Pyromb assumes that the id field for reaches, confluences and centroids are globally unique. The dictionary that holds the ids to map these to an integer id required by RORB is shared across the three entities, therefore when these ids are not globally unique the order of connection is disrupted and RORB fails to build the catg file.

Solution is to use separate dictionaries, one for the reaches, confluences and centroids and only require unique ids within each dataset.