Opened 3 years ago

Closed 13 months ago

#3246 closed enhancement (fixed)

r.in.srtm: patch to support SRTM water bodies import (SWBD)

Reported by: stjo Owned by: grass-dev@…
Priority: normal Milestone: 7.6.0
Component: Python Version: svn-releasebranch72
Keywords: r.in.srtm Cc:
CPU: Unspecified Platform: All

Description

I developed an enhancement for r.in.srtm to import SRTM water bodies in the .raw format and .raw.zip format, e.g. from https://dds.cr.usgs.gov/srtm/version2_1/SWBD/ Internally, it uses r.in.bin and is activated by the flag 'w' for 'water'.

Maybe someone can check my changes and take a look if my python coding Style is ok. :)

Attachments (2)

r.in.srtm.diff (11.7 KB) - added by neteler 3 years ago.
enhancement patch
r_in_srtm_luca.diff (11.4 KB) - added by neteler 3 years ago.
Patch updated by lucadelu

Download all attachments as: .zip

Change History (19)

Changed 3 years ago by neteler

Attachment: r.in.srtm.diff added

enhancement patch

comment:1 Changed 3 years ago by lucadelu

I updated the patch, but I'm not able to test it because there are no raw files in ​https://dds.cr.usgs.gov/srtm/version2_1/SWBD/. In the zip files there are only shapefile.

Changed 3 years ago by neteler

Attachment: r_in_srtm_luca.diff added

Patch updated by lucadelu

comment:2 Changed 3 years ago by stjo

I'm really sorry for the wrong link.

If you still want to test my changes, the correct link is: https://e4ftl01.cr.usgs.gov/SRTM/SRTMSWBD.003/2000.02.11/

comment:3 Changed 2 years ago by martinl

Milestone: 7.2.17.2.2

comment:4 Changed 2 years ago by martinl

Milestone: 7.2.27.4.0

All enhancement tickets should be assigned to 7.4 milestone.

comment:5 Changed 21 months ago by neteler

Milestone: 7.4.07.4.1

Ticket retargeted after milestone closed

comment:6 in reply to:  2 Changed 19 months ago by lucadelu

Replying to stjo:

I'm really sorry for the wrong link.

If you still want to test my changes, the correct link is: https://e4ftl01.cr.usgs.gov/SRTM/SRTMSWBD.003/2000.02.11/

Sorry I cannot access again to this link. It seems it requires special permission, I already authorized LP DAAC on my account.

comment:8 Changed 19 months ago by lucadelu

GDAL doesn't support this format by default, reading a little bit more about the data it seems that is is only the line coast and they also provide shapefile for this dataset https://lta.cr.usgs.gov/srtm_water_body_dataset

I think the shapefile is more useful than raster, if you really need raster you can rasterize the vector.

comment:9 in reply to:  8 Changed 19 months ago by neteler

Replying to lucadelu:

I think the shapefile is more useful than raster, if you really need raster you can rasterize the vector.

I think the idea is that their raster mask precisely matches what was used in the processing chain. to reach that with self-rasterized vector maps may lead to slightly different results.

comment:10 Changed 19 months ago by lucadelu

In 72569:

r.in.srtm: added support to SRTM SWBD, see #3246

comment:11 Changed 19 months ago by rouault

comment:12 Changed 16 months ago by neteler

Milestone: 7.4.17.4.2

comment:13 in reply to:  10 ; Changed 13 months ago by neteler

Replying to lucadelu:

In 72569:

r.in.srtm: added support to SRTM SWBD, see #3246

Is this ticket done?

comment:14 Changed 13 months ago by martinl

Milestone: 7.4.27.6.0

All enhancement tickets should be assigned to 7.6 milestone.

comment:15 in reply to:  13 Changed 13 months ago by lucadelu

Replying to neteler:

Is this ticket done?

Yes, to me it seems done. Maybe one more test could useful

comment:16 Changed 13 months ago by lucadelu

Closing, reopen if needed

comment:17 Changed 13 months ago by martinl

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.