<div dir="ltr">Hi, can we specify overview sizes exactly? I have this odd grid that is 36000x17999, and I get consequently yucky overview sizes: <div><br></div><div>gdal_create -outsize 36000 17999 -ot Int8 -co SPARSE_OK=YES -a_srs EPSG:4326 -a_ullr 0 17999 0 36000 weird.tif<br>gdal_translate weird.tif cog.tif  -of COG<br>gdalinfo cog.tif | grep Overviews<br>#  Overviews: 18000x8999, 9000x4499, 4500x2249, 2250x1124, 1125x562, 562x281, 281x14</div><div><br></div><div>Should I worry about this?  Can the sizes be specified via Translate? (I can see how they could be generated externally and bundled, but I'm looking for a way at this high level). <br></div><div><br></div><div>( Maybe I shouldn't even care about the sizes ... and maybe I should resample the grid to be a better overall size, but I consider that out of scope here.)<br><div><div><br></div><div>I'm comparing with other COG creators, e.g. odc which makes tidy overviews ( I will explore how it's getting done). </div><div><br></div><div>import xarray<br>from odc.geo.xr import assign_crs<br>from odc.geo.cog import write_cog<br><br>ds = xarray.open_dataset("weird.tif")<br>ds = assign_crs(ds, crs="EPSG:4326")  ## do something to tag it as odc<br><br><br>write_cog(ds["band_data"], "odc.tif")<br>os.system("gdalinfo odc.tif | grep Overviews")<br>#  Overviews: 18000x9000, 9000x4500, 4500x2250, 2250x1125, 1125x563<br></div><div><br></div><div>Cheers, Mike</div><div><br></div><div><br></div><span class="gmail_signature_prefix">-- </span><br><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature">Michael Sumner<br>Software and Database Engineer<br>Australian Antarctic Division<br>Hobart, Australia<br>e-mail: <a href="mailto:mdsumner@gmail.com" target="_blank">mdsumner@gmail.com</a></div></div></div></div>