Re: [gdal-dev] georeferenced but not georeferenced?

2021-11-18 Thread Matt.Wilkie
Thank you Even, especially for highlighting a DEM should be used. I 'knew' that but hadn't taken the time to fully ingest the meaning. It's drastically changed how I'm approaching this project. -Matt From: Even Rouault Sent: November 10, 2021 2:16 PM To: Matt.Wilkie ; gdal-dev@lists.osgeo.org

[gdal-dev] Moving GDAL GRASS driver in a dedicated repository ?

2021-11-18 Thread Even Rouault
Hi, (writing to both GDAL and GRASS lists) Working on the transition to CMake as the GDAL build system, the particular status of the GRASS driver in GDAL raised my attention. (The following is based on my understanding. It has been ages since I didn't try this...) This driver is a bit odd

Re: [gdal-dev] setting MAX_Z_ERROR on overviews compressed with LERC_DEFLATE

2021-11-18 Thread Rahkonen Jukka (MML)
Hi, I have no experience on 32 bit images but play with gdaladdo and compression options and report what you find. External overviews (-ro) are handy for testing because you can simply rename or delete the .ovr file and make new run with other options. External overviews take some more space th

Re: [gdal-dev] setting MAX_Z_ERROR on overviews compressed with LERC_DEFLATE

2021-11-18 Thread Duarte Carreira
Hi Even. I created a ticket: https://github.com/OSGeo/gdal/issues/4848 Thanks. >We would need a MAX_Z_ERROR_OVERVIEW config option for that. Please >file an enhancement ticket > >Even >Le 18/11/2021 à 12:44, Duarte Carreira a écrit : >>* Hi there. ** I am looking into compressing overviews f

Re: [gdal-dev] setting MAX_Z_ERROR on overviews compressed with LERC_DEFLATE

2021-11-18 Thread Duarte Carreira
Well, it didn't even occur to me to compress the overviews with translate... I was expecting a bit more compressing from lerc... About tif 32bit, what compression do you think would yield better ratios? Thanks. Rahkonen Jukka (MML) escreveu no dia quinta, 18/11/2021 à(s) 12:41: > Hi, > > > > I

Re: [gdal-dev] ogr2ogr, perform queries to obtain values from the database

2021-11-18 Thread Rahkonen Jukka (MML)
Hi, I would suggest to consider other options first. * Use OGR foreign data wrapper https://github.com/pramsey/pgsql-ogr-fdw and make the shapefile to appear as a PostGIS table. The you can make the JOIN in your PostGIS. * Add both the shapefile and the classification table from Postgr

[gdal-dev] ogr2ogr, perform queries to obtain values from the database

2021-11-18 Thread Andrés Nadal
Hello. Excuse me my English, it's not my native language. I need to convert the names (string) of classes, in some fields of a Shapefile, to the respective numerical values of the database. In some cases, the fields have up to 3 different classes, for different rows. CLASS A = 1 CLASS B = 2 CLA

Re: [gdal-dev] Black borders after reprojection GDAL_WARP

2021-11-18 Thread Even Rouault
Black borders are completely expected: reprojection changes the geometry of the image. That said, if the area of interest is sufficiently small and the geometry change being approximatively an affine transformation, you can try https://gdal.org/programs/gdalmove.html instead of gdalwarp to onl

Re: [gdal-dev] setting MAX_Z_ERROR on overviews compressed with LERC_DEFLATE

2021-11-18 Thread Even Rouault
We would need a MAX_Z_ERROR_OVERVIEW config option for that. Please file an enhancement ticket Even Le 18/11/2021 à 12:44, Duarte Carreira a écrit : Hi there. I am looking into compressing overviews for a DEM, with LERC_DEFLATE and it works. But I'm trying to set the precision loss and get b

Re: [gdal-dev] Black borders after reprojection GDAL_WARP

2021-11-18 Thread Lorenzo Di Giacomo
Hi Carl, thanks for your reply, i noticed that it happens even if i just reproject the image, without cutting. Of course the dstalpha works, but it increases the size of the image and it changes its nature (adding another band) since this operation is an intermediate operation the resulting image c

Re: [gdal-dev] Black borders after reprojection GDAL_WARP

2021-11-18 Thread Carl Godkin
Hi Lorenzo, I have faced this and there are two things to consider. First, you can specify the georeferenced extents _and_ the SRS of the extents using something like this: gdalwarp -t_srs EPSG:3857 \ -te_srs EPSG:4326 -te -109 32 -102 36 \ input.tif output.tif Note that I

Re: [gdal-dev] setting MAX_Z_ERROR on overviews compressed with LERC_DEFLATE

2021-11-18 Thread Rahkonen Jukka (MML)
Hi, I made some tests with an 8 bit RGB image. First observation was that gdaladdo supports lerc_deflate (even it is not documented), but it does not support “MAX_Z_ERROR”. This yields same sized ovr file with or without max_z_error. gdaladdo -ro lerc_def2.tif --config compress_overview lerc_def

[gdal-dev] setting MAX_Z_ERROR on overviews compressed with LERC_DEFLATE

2021-11-18 Thread Duarte Carreira
Hi there. I am looking into compressing overviews for a DEM, with LERC_DEFLATE and it works. But I'm trying to set the precision loss and get better compression, since for overviews I don't really care that much. Ok, so the question is how to set the MAX_Z_ERROR for overviews compressed with LERC_

Re: [gdal-dev] GDALWMS - error: TCP connection reset by peer

2021-11-18 Thread Rahkonen Jukka (MML)
Hi, It seems that the WMS server is closing the door and there is nothing else to do on the GDAL side except to try again later. Contact the WMS service maintainer and report your troubles. They may be able to provide you a more reliable service especially if you are ready to pay for it. -Jukk

[gdal-dev] GDALWMS - error: TCP connection reset by peer

2021-11-18 Thread Roman Breitfuss-Schiffer
Dear all! We are running a Python application an a linux distribution (RedHat) which creates clips in MBTILES format from a WMS. We are using the Python-API and are basically doing something like this: src_ds = gdal.Warp(     tmp_file,     ds_in,     format='GTiff',     outputBounds=[bbox[0],