1GDAL_RETILE(1) GDAL GDAL_RETILE(1)
2
3
4
6 gdal_retile - Retiles a set of tiles and/or build tiled pyramid levels.
7
9 gdal_retile.py [-v] [-co NAME=VALUE]* [-of out_format] [-ps pixelWidth pixelHeight]
10 [-overlap val_in_pixel]
11 [-ot {Byte/Int8/Int16/UInt16/UInt32/Int32/Float32/Float64/
12 CInt16/CInt32/CFloat32/CFloat64}]'
13 [ -tileIndex tileIndexName [-tileIndexField tileIndexFieldName]]
14 [ -csv fileName [-csvDelim delimiter]]
15 [-s_srs srs_def] [-pyramidOnly]
16 [-r {near/bilinear/cubic/cubicspline/lanczos}]
17 -levels numberoflevels
18 [-useDirForEachRow] [-resume]
19 -targetDir TileDirectory input_files
20
22 This utility will retile a set of input tile(s). All the input tile(s)
23 must be georeferenced in the same coordinate system and have a matching
24 number of bands.
25
26 Optionally pyramid levels are generated. All pyramid levels are gener‐
27 ated from the input tiles (not from previous levels).
28
29 It is possible to generate shape file(s) for the tiled output.
30
31 If your number of input tiles exhausts the command line buffer, use the
32 general --optfile option
33
34 -targetDir <directory>
35 The directory where the tile result is created. Pyramids are
36 stored in sub-directories numbered from 1. Created tile
37 names have a numbering schema and contain the name of the source
38 tiles(s)
39
40 -of <format>
41 Select the output format. Starting with GDAL 2.3, if not speci‐
42 fied, the format is guessed from the extension (previously was
43 GTiff). Use the short format name.
44
45 -co <NAME=VALUE>
46 Many formats have one or more optional creation options that can
47 be used to control particulars about the file created. For in‐
48 stance, the GeoTIFF driver supports creation options to control
49 compression, and whether the file should be tiled.
50
51 The creation options available vary by format driver, and some
52 simple formats have no creation options at all. A list of op‐
53 tions supported for a format can be listed with the --formats
54 command line option but the documentation for the format is the
55 definitive source of information on driver creation options.
56 See Raster drivers format specific documentation for legal cre‐
57 ation options for each format.
58
59 -ot <type>
60 Force the output image bands to have a specific data type sup‐
61 ported by the driver, which may be one of the following: Byte,
62 Int8, UInt16, Int16, UInt32, Int32, UInt64, Int64, Float32,
63 Float64, CInt16, CInt32, CFloat32 or CFloat64.
64
65 -ps <pixelsize_x> <pixelsize_y>
66 Pixel size to be used for the output file. If not specified,
67 256 x 256 is the default
68
69 -overlap< <val_in_pixel>
70 Overlap in pixels between consecutive tiles. If not specified, 0
71 is the default
72
73 New in version 2.2.
74
75
76 -levels <numberOfLevels>
77 Number of pyramids levels to build.
78
79 -v Generate verbose output of tile operations as they are done.
80
81 -pyramidOnly
82 No retiling, build only the pyramids
83
84 -r <algorithm>
85 Resampling algorithm, default is near
86
87 -s_srs <srs_def>
88 Source spatial reference to use. The coordinate systems that
89 can be passed are anything supported by the OGRSpatialRefer‐
90 ence.SetFromUserInput() call, which includes EPSG, PCS, and
91 GCSes (i.e. EPSG:4296), PROJ.4 declarations (as above), or the
92 name of a .prj file containing well known text. If no srs_def
93 is given, the srs_def of the source tiles is used (if there
94 is any). The srs_def will be propagated to created tiles (if
95 possible) and to the optional shape file(s)
96
97 -tileIndex <tileIndexName>
98 The name of shape file containing the result tile(s) index
99
100 -tileIndexField <tileIndexFieldName>
101 The name of the attribute containing the tile name
102
103 -csv <csvFileName>
104 The name of the csv file containing the tile(s) georeferencing
105 information. The file contains 5 columns: tile‐
106 name,minx,maxx,miny,maxy
107
108 -csvDelim <column delimiter>
109 The column delimiter used in the CSV file, default value is a
110 semicolon ";"
111
112 -useDirForEachRow
113 Normally the tiles of the base image are stored as described in
114 -targetDir. For large images, some file systems have perfor‐
115 mance problems if the number of files in a directory is to big,
116 causing gdal_retile not to finish in reasonable time. Using
117 this parameter creates a different output structure. The tiles
118 of the base image are stored in a sub-directory called 0, the
119 pyramids in sub-directories numbered 1,2,.... Within each of
120 these directories another level of sub-directories is created,
121 numbered from 0...n, depending of how many tile rows are needed
122 for each level. Finally, a directory contains only the tiles for
123 one row for a specific level. For large images a performance im‐
124 provement of a factor N could be achieved.
125
126 -resume
127 Resume mode. Generate only missing files.
128
129 NOTE:
130 gdal_retile.py is a Python script, and will only work if GDAL was
131 built with Python support.
132
134 Christian Mueller <christian.mueller@nvoe.at>
135
137 1998-2023
138
139
140
141
142 Oct 30, 2023 GDAL_RETILE(1)