<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";
mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:"Calibri","sans-serif";
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-family:"Calibri","sans-serif";
mso-fareast-language:EN-US;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-AU link=blue vlink=purple><div class=WordSection1><p class=MsoNormal>Hi guys,<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I’ve got an interesting one – I have some GeoTIFF Files that I’ve converted to EPSG:3857 from GeoStationary as follows:<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal># gdalwarp -tr 2000 2000 -co tfw=yes -t_srs epsg:3857 -te 10018754.17 -7361866.11 20037508.34 -0.00 /storage/sat_data/20150824/IDE00422.201508240100.tif /storage/tmp/IDE00422.201508240100.tif<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Using gdalinfo reveals the following about the newly created GeoTIFF file:<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal># gdalinfo IDE00422.201508240100.tif<o:p></o:p></p><p class=MsoNormal>Driver: GTiff/GeoTIFF<o:p></o:p></p><p class=MsoNormal>Files: IDE00422.201508240100.tif<o:p></o:p></p><p class=MsoNormal>Size is 5009, 3681<o:p></o:p></p><p class=MsoNormal>Coordinate System is:<o:p></o:p></p><p class=MsoNormal>PROJCS["WGS 84 / Pseudo-Mercator",<o:p></o:p></p><p class=MsoNormal> GEOGCS["WGS 84",<o:p></o:p></p><p class=MsoNormal> DATUM["WGS_1984",<o:p></o:p></p><p class=MsoNormal> SPHEROID["WGS 84",6378137,298.257223563,<o:p></o:p></p><p class=MsoNormal> AUTHORITY["EPSG","7030"]],<o:p></o:p></p><p class=MsoNormal> AUTHORITY["EPSG","6326"]],<o:p></o:p></p><p class=MsoNormal> PRIMEM["Greenwich",0],<o:p></o:p></p><p class=MsoNormal> UNIT["degree",0.0174532925199433],<o:p></o:p></p><p class=MsoNormal> AUTHORITY["EPSG","4326"]],<o:p></o:p></p><p class=MsoNormal> PROJECTION["Mercator_1SP"],<o:p></o:p></p><p class=MsoNormal> PARAMETER["central_meridian",0],<o:p></o:p></p><p class=MsoNormal> PARAMETER["scale_factor",1],<o:p></o:p></p><p class=MsoNormal> PARAMETER["false_easting",0],<o:p></o:p></p><p class=MsoNormal> PARAMETER["false_northing",0],<o:p></o:p></p><p class=MsoNormal> UNIT["metre",1,<o:p></o:p></p><p class=MsoNormal> AUTHORITY["EPSG","9001"]],<o:p></o:p></p><p class=MsoNormal> EXTENSION["PROJ4","+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs"],<o:p></o:p></p><p class=MsoNormal> AUTHORITY["EPSG","3857"]]<o:p></o:p></p><p class=MsoNormal>Origin = (10018754.169999999925494,0.000000000000000)<o:p></o:p></p><p class=MsoNormal>Pixel Size = (2000.000000000000000,-2000.000000000000000)<o:p></o:p></p><p class=MsoNormal>Metadata:<o:p></o:p></p><p class=MsoNormal> AREA_OR_POINT=Area<o:p></o:p></p><p class=MsoNormal>Image Structure Metadata:<o:p></o:p></p><p class=MsoNormal> INTERLEAVE=BAND<o:p></o:p></p><p class=MsoNormal>Corner Coordinates:<o:p></o:p></p><p class=MsoNormal>Upper Left (10018754.170, 0.000) ( 90d 0' 0.00"E, 0d 0' 0.01"N)<o:p></o:p></p><p class=MsoNormal>Lower Left (10018754.170,-7362000.000) ( 90d 0' 0.00"E, 55d 0' 2.48"S)<o:p></o:p></p><p class=MsoNormal>Upper Right (20036754.170, 0.000) (179d59'35.61"E, 0d 0' 0.01"N)<o:p></o:p></p><p class=MsoNormal>Lower Right (20036754.170,-7362000.000) (179d59'35.61"E, 55d 0' 2.48"S)<o:p></o:p></p><p class=MsoNormal>Center (15027754.170,-3681000.000) (134d59'47.81"E, 31d22'14.91"S)<o:p></o:p></p><p class=MsoNormal>Band 1 Block=5009x1 Type=Byte, ColorInterp=Gray<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>It looks like the map has the correct coordinates however when I run the gdal2tiles program it errors out:<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>gdal2tiles.py -k -g <api_key> IDE00422.201508240100.tif mercour<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>ERROR 6: EPSG PCS/GCS code 900913 not found in EPSG support files. Is this a valid<o:p></o:p></p><p class=MsoNormal>EPSG coordinate system?<o:p></o:p></p><p class=MsoNormal>ERROR 6: No translation for an empty SRS to PROJ.4 format is known.<o:p></o:p></p><p class=MsoNormal>ERROR 6: No translation for an empty SRS to PROJ.4 format is known.<o:p></o:p></p><p class=MsoNormal>Generating Base Tiles:<o:p></o:p></p><p class=MsoNormal>ERROR 5: Illegal values for buffer size<o:p></o:p></p><p class=MsoNormal>ERROR 5: Illegal values for buffer size<o:p></o:p></p><p class=MsoNormal>Traceback (most recent call last):<o:p></o:p></p><p class=MsoNormal> File "/usr/bin/gdal2tiles.py", line 2262, in <module><o:p></o:p></p><p class=MsoNormal> gdal2tiles.process()<o:p></o:p></p><p class=MsoNormal> File "/usr/bin/gdal2tiles.py", line 478, in process<o:p></o:p></p><p class=MsoNormal> self.generate_base_tiles()<o:p></o:p></p><p class=MsoNormal> File "/usr/bin/gdal2tiles.py", line 1276, in generate_base_tiles<o:p></o:p></p><p class=MsoNormal> dsquery.WriteRaster(wx, wy, wxsize, wysize, data, band_list=list(range(1,self.dataBandsCount+1)))<o:p></o:p></p><p class=MsoNormal> File "/usr/lib/python2.7/dist-packages/osgeo/gdal.py", line 796, in WriteRaster<o:p></o:p></p><p class=MsoNormal> buf_pixel_space, buf_line_space, buf_band_space )<o:p></o:p></p><p class=MsoNormal>TypeError: not a string<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I’m running “GDAL 1.10.1, released 2013/08/26” on Debian Jessie. I’ve read that version 1.6 had this issue as it didn’t know what EPSG:3857 is but I’m running 1.10 so it can’t be that.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Cheers, Mike<o:p></o:p></p></div></body></html>