Open fmaussion opened 1 year ago
We did not implement a fix for this in RGI 7.0 because the problem is an inventory problem, not something that should be solved algorithmically. I might be wrong, but I don't think that there is an easy fix that solves all potential issues of this type without creating issues elsewhere.
If this problem bothers you, one possible easy fix would be to use .buffer()
on the problematic geometries. I'd recommend to apply it in some kind of map projection, for example the suggested UTM zone from RGI.
Here is an example for a bad complex in RGI 17
First transform to UTM:
odf_utm = odf_merged.to_crs({'proj':'utm', 'zone':odf_merged.iloc[0].utm_zone})
odf_utm.plot(ec='k');
The black lines in the center are the issue. Buffering with 1 meter resolve some of the problems:
odf_utm.buffer(1).plot(ec='k');
Note however that this increased the area of the glacier by 1 m everywhere, i.e. in this case 0.1km2 or 0.1%.
To solve "all" visible problems in this rather extreme example, a buffer of 5 meters is necessary:
To use with caution!
RGI version RGI v7.0 - glacier complex product
Describe the issue Sometimes the glacier complex product looks like this:
if you zoom in, you see that the outlines are "close", but not quite:
Expected outcome Ideally the product should be able to deal with this.
Suggested solution Some shapely tools were suggested in https://github.com/GLIMS-RGI/rgi7_scripts/issues/74, but it did not seem to work well.