Opened 13 years ago

Closed 9 years ago

#288 closed defect (worksforme)

GDAL - Datum shift issue (WGS84, NAD27, NAD83)

Reported by: tcgeophysics Owned by: osgeo4w-dev@…
Priority: major Component: Package
Version: Keywords: Datum shift grids NAD27 proj
Cc:

Description

Hi All,

I am encountering a gdalwarp issue that I have a hard time narrowing down...

I have a Canadian DEM (CDED) in USGS DEM format in Lat/Lon NAD83 (EPSG 4269) and I want to convert it to an ER Mapper ERS format in UTM Zone 16 NAD27 (EPSG 26716).

The command I use is the following:

gdalwarp -s_srs EPSG:4269 -t_srs EPSG:26716 -of ERS 042c_0100_deme.dem 042c_0100_deme_NAD27UTMZ16N.ers

And the output is:

ERROR 1: No such file or directory ERROR 1: GDALSuggestedWarpOutput() failed because the passed transformer failed.

GDAL was installed using osgeo4w.exe installer on my Window 7 machine.

After doing some research it seems that datum shift grids may not be built by default with Proj.4. Is there other dependencies that may affect datum shifts?

How can I check that datum shift grids were built and which ones?

What can be an approach to add other datum shift grids?

Thanks

Thomas

Change History (2)

comment:1 by warmerdam, 13 years ago

Hmm, I'm not at all sure where the "No such file or directory" is coming from. I've tried a somewhat similar command here and it works ok, but this was not on windows:

warmerdam@gdal:~$ gdalwarp -t_srs EPSG:26716 -of ERS utm.tif out.ers
Creating output file that is 644P x 644L.
Processing input file utm.tif.
0...10...20...30...40...50...60...70...80...90...100 - done.

If you set the environment variable PROJ_DEBUG to a value like "4" you should be able to see info in the console when PROJ.4 uses the grid shift files.

ie.

C:\> SET PROJ_DEBUG=4
C:\> gdalwarp ...

I see:

pj_open_lib(proj_def.dat): call fopen(/home/warmerdam/local/bld/share/proj/proj_def.dat) - succeeded

pj_open_lib(conus): call fopen(/home/warmerdam/local/bld/share/proj/conus) - succeeded

Ctable2 Conterminous United States 273x121: LL=(-131,20) UR=(-63,50)

pj_open_lib(alaska): call fopen(/home/warmerdam/local/bld/share/proj/alaska) - succeeded

Ctable2 Alaska 529x249: LL=(-194,46) UR=(-128,77)

pj_open_lib(ntv2_0.gsb): call fopen(/home/warmerdam/local/bld/share/proj/ntv2_0.gsb) - failed

pj_open_lib(ntv1_can.dat): call fopen(/home/warmerdam/local/bld/share/proj/ntv1_can.dat) - succeeded

NTv1 393x177: LL=(-142,40) UR=(-44,84)
pj_open_lib(conus): call fopen(/home/warmerdam/local/bld/share/proj/conus) - succeeded

pj_apply_gridshift(): used Conterminous United States
pj_apply_gridshift(): used Conterminous United States
...

comment:2 by jef, 9 years ago

Resolution: worksforme
Status: newclosed

quite dated. probably fixed with a later gdal package. feel free to reopen.

Note: See TracTickets for help on using tickets.