-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dissolve internally draining areas in delineated watershed #80
Comments
Test shapesNHD
DRB
|
Update from @dtarb shows that this is performing as expected with RWD's current capabilities:
|
Closing, since the resolutions proposed do not involve dissolving the holes. |
Here is a patch of the beginning of this work (NHD working, DRB in progress). The solution involves reading the shapefile in via fiona and removing each polygon's internal rings via shapely — manipulating the shapefiles via fiona was part of an earlier approach replaced by the work here. I didn't find it to have too heavy of a performance toll, though more extensive testing would be needed to know for sure. |
@dtarb this could be the basis for a future fix via RWD ^ |
This certainly looks promising. I implemented this patch in a test branch and it resolved the hole problem at the location |
Recognizing that poor performance is a problem, here is one option towards a solution.
The first step above will need to be done outside of RWD, as the simplification is done outside of RWD (as the code is now structured). The second step would only be needed if/when we implement full resolution downloads (see WikiWatershed/model-my-watershed#2717). The time consuming full resolution hole removal would only run on a very small number of cases. There is only one test case I have where this occurs. There is a risk that the simplification process may remove holes and thus the approach of identifying watersheds with holes from the simplified shapes may not be 100% reliable. Given that this would be a hypothetical small fraction of a small fraction of cases, I would suggest not concerning ourselves with this at this point. Additionally, hole removal is only needed for the NHD implementation. The Delaware implementation does not have any internally draining areas that are the cause of these holes, because data preparation for the Delaware used pit filling to remove sinks as part of preprocessing. (Although including it for completeness may be worthwhile in case there is ever new non pit filled data used in the Delaware.) My work on this is in https://github.com/WikiWatershed/rapid-watershed-delineation/tree/fixHoles |
Re-opening for future work, currently this is an enhancement. |
Holes in a delineated watershed should be dissolved out.
Description and test location here:
WikiWatershed/model-my-watershed#2703
The text was updated successfully, but these errors were encountered: