Re: [gdal-dev] Raster Strategies Examples

2010-08-09 Thread Brent Fraser
The steps you've listed below are correct for maximizing performance when 
viewing the raster at (or around) the native resolution of the data.  However, 
as you've found out, the performance can still be poor when trying to view the 
entire dataset.


The basic rule is that your application (mapserver?) should not have to open 
more than 4 to 8 raster files to render the view.  With that in mind (and since 
disk space is not a problem), create layers of the raster dataset at different 
scales, say a factor of 2, until you have only one image.


For example, if the resolution of your original data is 1 meter per pixel, your 
layers would look like the following.  Note the first eight layers are handled 
by the internal overviews you created with gdaladdo.


Pixel   Map Scale:
Size:   1:n
-   --
1 m 4,000
2   8,000
4   16,000
8   32k
16  64
32  128
64  250
128 500

Additional External Layers
256 1m
512 2m
10244m
20488m
409616m

To create the additional external layers, use GDAL's gdalbuiltvrt to create a 
VRT file of the original dataset.  You can then use gdal_retile.py or Maptiler 
to build the layers.


Best Regards,
Brent Fraser

Edi KARADUMI wrote:
I have read many strategies for raster performance, but i still have 
problems with my case. The posts that i have read explain the strategie, 
but are not very detailed. Im new to mapserver so i have problems 
implementing them. My case is: 

-about 6000 tiles that form the map 
-170mb each tile 
-aproximately 1.2T of iamges 
-i have 10T HD and i think disk space is not a problem for me 
-tile format is TIF 
-tile size 9375x6250 pixels 

The strategy i have implemented and the problems i have 

-First i divided the tiles in 60 folders, to increase the performance in 
disk seek/read. 

-Than i transformed source files into internally tiles with the command 
   gdal_translate -of GTiff -co TILED=YES original.tif tiled.tif 

-i used gdaladdo to add internal pyramids 

   gdaladdo -r average 2 4 8 16 32 64 128 

-Created a tileindex using 
   gdaltindex -write_absolute_path MapAll.shp 
//server/Maps/Subfolder1/*.tif 

-Created a spatial index .qix file 
   shptree MapAll.shp 

-than added the layer to the mapfile without the .shp extension so the 
application can use the .qix 

as you may know, i have very slow performance when i zoom out and im 
stucked here. As i have read i should make a copy of the tiles with 
reduced resolution. Merge the tiles together and use min/max scale to 
show different layers in different scales. the min/max scales i zoom 
in/out are 100/120. Now my questions are 

- How can i calculate the scale where i should create another layer of 
the tiles, or i shoud see it with some tests? 

- how much should be the resolution of the new layer? 

- is there any tools or program to merge the tiles? merging 6000 tiles 
with the gdalwarp by writing the command by myself is frustrating 

- how many tiles should i merge together to create the new layer? (how 
many tiles should have the new layer) i know that in each zoomscale its 
better to appear only one tile but i dont know how to calculate it 

- the tiles that i should merge are the originals or those with internal 
tiling and overviews? 





___
gdal-dev mailing list
gdal-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/gdal-dev


___
gdal-dev mailing list
gdal-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/gdal-dev


Re: [gdal-dev] Raster Strategies Examples

2010-08-04 Thread brian
Edi,

Personaly I beleve gdalwarp is the wrong tool for the job, you already
have it all set up for mapserver so just use shp2img.



On Mon, 2010-08-02 at 17:14 +0200, Edi KARADUMI wrote:
 as you may know, i have very slow performance when i zoom out and im
 stucked here. As i have read i should make a copy of the tiles with
 reduced resolution. Merge the tiles together and use min/max scale to
 show different layers in different scales. the min/max scales i zoom
 in/out are 100/120. Now my questions are 
 
 - How can i calculate the scale where i should create another layer of
 the tiles, or i shoud see it with some tests? 
 
 - how much should be the resolution of the new layer? 
 
 - is there any tools or program to merge the tiles? merging 6000 tiles
 with the gdalwarp by writing the command by myself is frustrating 
 
 - how many tiles should i merge together to create the new layer? (how
 many tiles should have the new layer) i know that in each zoomscale
 its better to appear only one tile but i dont know how to calculate
 it 
 
 - the tiles that i should merge are the originals or those with
 internal tiling and overviews? 

___
gdal-dev mailing list
gdal-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/gdal-dev


[gdal-dev] Raster Strategies Examples

2010-08-02 Thread Edi KARADUMI
I have read many strategies for raster performance, but i still have
problems with my case. The posts that i have read explain the strategie, but
are not very detailed. Im new to mapserver so i have problems implementing
them. My case is:

-about 6000 tiles that form the map
-170mb each tile
-aproximately 1.2T of iamges
-i have 10T HD and i think disk space is not a problem for me
-tile format is TIF
-tile size 9375x6250 pixels

The strategy i have implemented and the problems i have

-First i divided the tiles in 60 folders, to increase the performance in
disk seek/read.

-Than i transformed source files into internally tiles with the command
   gdal_translate -of GTiff -co TILED=YES original.tif tiled.tif

-i used gdaladdo to add internal pyramids

   gdaladdo -r average 2 4 8 16 32 64 128

-Created a tileindex using
   gdaltindex -write_absolute_path MapAll.shp
//server/Maps/Subfolder1/*.tif

-Created a spatial index .qix file
   shptree MapAll.shp

-than added the layer to the mapfile without the .shp extension so the
application can use the .qix

as you may know, i have very slow performance when i zoom out and im stucked
here. As i have read i should make a copy of the tiles with reduced
resolution. Merge the tiles together and use min/max scale to show different
layers in different scales. the min/max scales i zoom in/out are
100/120. Now my questions are

- How can i calculate the scale where i should create another layer of the
tiles, or i shoud see it with some tests?

- how much should be the resolution of the new layer?

- is there any tools or program to merge the tiles? merging 6000 tiles with
the gdalwarp by writing the command by myself is frustrating

- how many tiles should i merge together to create the new layer? (how many
tiles should have the new layer) i know that in each zoomscale its better to
appear only one tile but i dont know how to calculate it

- the tiles that i should merge are the originals or those with internal
tiling and overviews?
___
gdal-dev mailing list
gdal-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/gdal-dev