Artifacts in Hillshade Raster

View: New views
5 Messages — Rating Filter:   Alert me  

Artifacts in Hillshade Raster

by Adam Ratcliffe-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

I've been generating hillshade images using the SRTM3 data, these are looking good but I've noticed some artifacts around the area of the Southern Alps of New Zealand.  These can be seen in this sample image: http://test.geosmart.co.nz/images/relief-artifacts.png

Being a little bit new to this I'm neither sure of why the artifacts exist and how to remove them in the processing of the data.  So far I've experimented with some of the options to gdalwarp, on the Hiking/Biking maps wiki page it was suggested to pass "-wt Float32 -ot Float32" to the gdalwarp call - I observed no difference with these options.  I also tried setting the error threshold '-et' option to 0 which had no effect.

Any suggestions on how to tackle this problem are much appreciated.

Cheers
Adam
_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users

Re: Artifacts in Hillshade Raster

by Holger Schöner :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi Adam,

> I've been generating hillshade images using the SRTM3 data, these are
> looking good but I've noticed some artifacts around the area of the
> Southern Alps of New Zealand.  These can be seen in this sample image:
> http://test.geosmart.co.nz/images/relief-artifacts.png

I noticed some improvements when leaving out the -dstnodata option, but of
course there are still artefacts left (only some hole-filling could remove
that, more or less plausibly, and I do not know of any automatic way to
achieve that). So for small artefacts, this seems to work rather well, while
for larger ones, they seem to be still pretty well visible.

In the Alps (New Zealand or Europe ...) there will probably still be another
issue making this worse: I experimented with leaving out the mentioned
option for generating hill shadings and reliefs; when looking at the
generated reliefs, it seems like now the missing parts are filled with the
color for the lowest configured elevation (for me eg. dark green instead of
black); this is an improvement (in my eyes), but if dark green spots appear
in the grey or white of high mountains, then that of course still is pretty
striking. As said, I think the only way around that is using filling for
voids, or using preprocessed data, eg. CIAT/CSI/CGIAR, mentioned on the
HikingBikingMaps wiki page. These currently have licensing issues because
they are non-commercial only; but with the possible move to ODbL in the
future, and the possibility to license products other than CC-BY-SA (in my
understanding) this can be resolved, if non-commercial use is sufficient for
you (otherwise you might have to negotiate for other licenses or datasets).

> and how to remove them in the processing of the data.  So far I've
> experimented with some of the options to gdalwarp, on the Hiking/Biking
> maps wiki page it was suggested to pass "-wt Float32 -ot Float32" to the

These I introduced, because I was generating maps for rather small areas
with a high level of details. When doing interpolation of DEM data for
these, I noticed steps instead of smooth elevation transitions, which arose
because of the limited elevation resolution of the default int values. For
large areas, you might want to leave them out as any effects will probably
not be noticeable, and the size of the files is multiplied, such that any
memory limits will be hit earlier that without the floats.

Yours, Holger
_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users

Re: Artifacts in Hillshade Raster

by Lars Lingner-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Adam Ratcliffe schrieb:
> Hi,
>
> I've been generating hillshade images using the SRTM3 data, these are looking good but I've noticed some artifacts around the area of the Southern Alps of New Zealand.  These can be seen in this sample image: http://test.geosmart.co.nz/images/relief-artifacts.png
>
> Being a little bit new to this I'm neither sure of why the artifacts exist and how to remove them in the processing of the data.  So far I've experimented with some of the options to gdalwarp, on the Hiking/Biking maps wiki page it was suggested to pass "-wt Float32 -ot Float32" to the gdalwarp call - I observed no difference with these options.  I also tried setting the error threshold '-et' option to 0 which had no effect.
>
> Any suggestions on how to tackle this problem are much appreciated.
>


I'm doing also my first steps with generating hillshades. The wiki page
(HikingBikingMaps) helped a lot and I got my shades with the known
artifacts.

As I understand, these came from the SRTM3 data itself and can only be
fixed with more precise data. Now comes the SRTM30 [1] dataset in play.

The viewfinderpanorama website [2] lists also some alternative sources
for filling the gaps, but I just cant find a way how to process all the
data.

Does anyone have tried to combine/merge the datasets to fix the
artifacts? I would like to know the way how to do it. There is also the
SRTM4 dataset from CGIAR-CSI (with fixed gaps) but this is not an option
right now.

Lars

[1] http://dds.cr.usgs.gov/srtm/version2_1/SRTM30/
[2] http://www.viewfinderpanoramas.org/dem3.html

_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users

Re: Artifacts in Hillshade Raster

by Marcin Rudowski :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

2009/10/3 Adam Ratcliffe <adam.ratcliffe@...>:
> Hi,
>
> I've been generating hillshade images using the SRTM3 data, these are looking good but I've noticed some artifacts around the area of the Southern Alps of New Zealand.  These can be seen in this sample image: http://test.geosmart.co.nz/images/relief-artifacts.png
>


As already said, this is effect of not filled holes. There is no other
way than to use hole-filling software (search google for srtm and
filling etc). I don't remember what I used, it was probably some
window dialog clicking shareware, but gdal has some python script for
that (I didn't tried it).

In my case mountains in the middle had similar artefacts like Yours
(from right part of relief-artifacts.png)  and now look like that:
http://mapa.ump.waw.pl/ump-www/?zoom=12&lat=49.18671&lon=20.21316&layers=B00000FT

However, I doubt big holes on left part of Your image could be filled
nicely with anything other then different elevation source.


> Being a little bit new to this I'm neither sure of why the artifacts exist and how to remove them in the processing of the data.  So far I've experimented with some of the options to gdalwarp, on the Hiking/Biking maps wiki page it was suggested to pass "-wt Float32 -ot Float32" to the gdalwarp call - I observed no difference with these options.  I also tried setting the error threshold '-et' option to 0 which had no effect.
>
> Any suggestions on how to tackle this problem are much appreciated.
>

In this thread You can find my earlier notes concerning hill shading in mapnik:
http://www.nabble.com/My-patches-for-hill-shading-td22215531.html

I also based on mentioned Wiki(HikingBikingMaps), but made some
adjustment to improve quality and effect to my needs (interpolation,
fine alignment, composing methods), almost all patches are in recent
versions of Mapnik.
Just one note, I use a little modified mapnik and composite method:
grain_merge181, that compared to grain_merge has moved middle point
(value of no shading effect) from 128 to 181 to have bigger range of
shadows then highlights.

--
Marcin Rudowski
_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users

Re: Artifacts in Hillshade Raster

by Adam Ratcliffe-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I found some void filled data files for New Zealand on the viewfinderpanoramas site.  The provided files appeared to cover the area in which I'd observed the artifacts.  To use them I simply downloaded the corrected .hgt files and overwrote the corresponding .TIFF files in the SRTM3 dataset with the replacement TIFFs.  I then re-ran gdal_merge.py to create a unified DEM file which the hillshade images were generated from.  Unfortunately I'm still seeing the artifacts.

Cheers
Adam
________________________________________
From: mapnik-users-bounces@... [mapnik-users-bounces@...] On Behalf Of Lars Lingner [ml@...]
Sent: 05 October 2009 22:44
To: mapnik-users@...
Subject: Re: [Mapnik-users] Artifacts in Hillshade Raster

Adam Ratcliffe schrieb:
> Hi,
>
> I've been generating hillshade images using the SRTM3 data, these are looking good but I've noticed some artifacts around the area of the Southern Alps of New Zealand.  These can be seen in this sample image: http://test.geosmart.co.nz/images/relief-artifacts.png
>
> Being a little bit new to this I'm neither sure of why the artifacts exist and how to remove them in the processing of the data.  So far I've experimented with some of the options to gdalwarp, on the Hiking/Biking maps wiki page it was suggested to pass "-wt Float32 -ot Float32" to the gdalwarp call - I observed no difference with these options.  I also tried setting the error threshold '-et' option to 0 which had no effect.
>
> Any suggestions on how to tackle this problem are much appreciated.
>


I'm doing also my first steps with generating hillshades. The wiki page
(HikingBikingMaps) helped a lot and I got my shades with the known
artifacts.

As I understand, these came from the SRTM3 data itself and can only be
fixed with more precise data. Now comes the SRTM30 [1] dataset in play.

The viewfinderpanorama website [2] lists also some alternative sources
for filling the gaps, but I just cant find a way how to process all the
data.

Does anyone have tried to combine/merge the datasets to fix the
artifacts? I would like to know the way how to do it. There is also the
SRTM4 dataset from CGIAR-CSI (with fixed gaps) but this is not an option
right now.

Lars

[1] http://dds.cr.usgs.gov/srtm/version2_1/SRTM30/
[2] http://www.viewfinderpanoramas.org/dem3.html

_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users
_______________________________________________
Mapnik-users mailing list
Mapnik-users@...
https://lists.berlios.de/mailman/listinfo/mapnik-users