<html style="direction: ltr;">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body bidimailui-charset-is-forced="true" style="direction: ltr;">
    <p>Inline...</p>
    <p><br>
    </p>
    <div class="moz-cite-prefix">On 08/03/2023 14:33, Even Rouault
      wrote:<br>
    </div>
    <blockquote type="cite"
      cite="mid:a17513cc-3def-350e-807a-718e898eb94d@spatialys.com">
      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
      <p>Ah, the issue here is that the GeoTIFF keys in the .tif
        partially define the projection (or possibly the .tif.aux.xml
        contain this invalid WKT). But METHOD["unnamed"] means that the
        projection method is unknown, so it is logical that GDAL/PROJ
        can't compute geographic coordinates from projected coordinates.</p>
      <p><br>
      </p>
      <p>The output of "listgeo HiBar_21022022_A1.tif" might be useful
        to further diagnose.<br>
      </p>
      <p><br>
      </p>
    </blockquote>
    <p>I can't see any problem here:</p>
    <p><br>
    </p>
    <p><span style="font-family:monospace"><span
          style="color:#000000;background-color:#ffffff;">listgeo
          HiBar_21022022_A1.tif  </span><br>
        Geotiff_Information:
        <br>
          Version: 1
        <br>
          Key_Revision: 1.0
        <br>
          Tagged_Information:
        <br>
             ModelTiepointTag (2,3):
        <br>
                0                 0                 0                 <br>
                202245.240786848  421915.720555977  0                 <br>
             ModelPixelScaleTag (1,3):
        <br>
                0.125             0.125             1                 <br>
             End_Of_Tags.
        <br>
          Keyed_Information:
        <br>
             GTModelTypeGeoKey (Short,1): ModelTypeProjected
        <br>
             GTRasterTypeGeoKey (Short,1): RasterPixelIsArea
        <br>
             GTCitationGeoKey (Ascii,26): "PCS Name = Israel_TM_Grid"
        <br>
             GeographicTypeGeoKey (Short,1): Code-4141 (Israel 1993)
        <br>
             GeogAngularUnitsGeoKey (Short,1): Angular_Degree
        <br>
             GeogEllipsoidGeoKey (Short,1): Ellipse_GRS_1980
        <br>
             GeogSemiMajorAxisGeoKey (Double,1): 6378137           <br>
             GeogSemiMinorAxisGeoKey (Double,1): 6356752.31414036  <br>
             GeogInvFlatteningGeoKey (Double,1): 298.257222101     <br>
             GeogTOWGS84GeoKey (Double,7): -48              55
                      52                <br>
        0                0                0                 <br>
        0                 <br>
             ProjectedCSTypeGeoKey (Short,1): Code-2039 (Israel 1993 /
        Israeli TM Grid)
        <br>
             PCSCitationGeoKey (Ascii,15): "Israel_TM_Grid"
        <br>
             ProjLinearUnitsGeoKey (Short,1): Linear_Meter
        <br>
             End_Of_Keys.
        <br>
          End_Of_Geotiff.
        <br>
        <br>
        PCS = 2039 (Israel 1993 / Israeli TM Grid)
        <br>
        Projection = 18204 (Israeli TM)
        <br>
        Projection Method: CT_TransverseMercator
        <br>
          ProjNatOriginLatGeoKey: 31.734394 ( 31d44' 3.82"N)
        <br>
          ProjNatOriginLongGeoKey: 35.204517 ( 35d12'16.26"E)
        <br>
          ProjScaleAtNatOriginGeoKey: 1.000007
        <br>
          ProjFalseEastingGeoKey: 219529.584000 m
        <br>
          ProjFalseNorthingGeoKey: 626907.390000 m
        <br>
        GCS: 4141/Israel 1993
        <br>
        Datum: 6141/Israel 1993
        <br>
        Ellipsoid: 7019/GRS 1980 (6378137.00,6356752.31)
        <br>
        Prime Meridian: 8901/Greenwich (0.000000/  0d 0' 0.00"E)
        <br>
        TOWGS84: -48,55,52,0,0,0,0
        <br>
        Projection Linear Units: 9001/metre (1.000000m)
        <br>
        <br>
        Corner Coordinates:
        <br>
        Upper Left    (  202245.241,  421915.721)  ( 35d 1'32.11"E,
        29d53' 7.03"N)
        <br>
        Lower Left    (  202245.241,  418790.721)  ( 35d 1'32.29"E,
        29d51'25.54"N)
        <br>
        Upper Right   (  205370.241,  421915.721)  ( 35d 3'28.57"E,
        29d53' 7.17"N)
        <br>
        Lower Right   (  205370.241,  418790.721)  ( 35d 3'28.72"E,
        29d51'25.68"N)
        <br>
        Center        (  203807.741,  420353.221)  ( 35d 2'30.42"E,
        29d52'16.36"N)<br>
        <br>
      </span></p>
    <p>Then, after:</p>
    <p><br>
    </p>
    <p><span style="font-family:monospace"><span
          style="color:#000000;background-color:#ffffff;">gdal_translate
          -a_srs EPSG:2039 HiBar_21022022_A1.tif HiBar_21022022_A1b.tif</span><br>
      </span><span style="font-family:monospace"></span></p>
    <br>
    <p>The ERROR goes away and I get:</p>
    <p><br>
    </p>
    <p><span style="font-family:monospace"><span
          style="color:#000000;background-color:#ffffff;">gdalinfo
          HiBar_21022022_A1b.tif  </span><br>
        Driver: GTiff/GeoTIFF
        <br>
        Files: HiBar_21022022_A1b.tif
        <br>
        Size is 25000, 25000
        <br>
        Coordinate System is:
        <br>
        PROJCRS["Israel 1993 / Israeli TM Grid",
        <br>
           BASEGEOGCRS["Israel 1993",
        <br>
               DATUM["Israel 1993",
        <br>
                   ELLIPSOID["GRS 1980",6378137,298.257222101,
        <br>
                       LENGTHUNIT["metre",1]]],
        <br>
               PRIMEM["Greenwich",0,
        <br>
                   ANGLEUNIT["degree",0.0174532925199433]],
        <br>
               ID["EPSG",4141]],
        <br>
           CONVERSION["Israeli TM",
        <br>
               METHOD["Transverse Mercator",
        <br>
                   ID["EPSG",9807]],
        <br>
               PARAMETER["Latitude of natural origin",31.7343936111111,
        <br>
                   ANGLEUNIT["degree",0.0174532925199433],
        <br>
                   ID["EPSG",8801]],
        <br>
               PARAMETER["Longitude of natural origin",35.2045169444444,
        <br>
                   ANGLEUNIT["degree",0.0174532925199433],
        <br>
                   ID["EPSG",8802]],
        <br>
               PARAMETER["Scale factor at natural origin",1.0000067,
        <br>
                   SCALEUNIT["unity",1],
        <br>
                   ID["EPSG",8805]],
        <br>
               PARAMETER["False easting",219529.584,
        <br>
                   LENGTHUNIT["metre",1],
        <br>
                   ID["EPSG",8806]],
        <br>
               PARAMETER["False northing",626907.39,
        <br>
                   LENGTHUNIT["metre",1],
        <br>
                   ID["EPSG",8807]]],
        <br>
           CS[Cartesian,2],
        <br>
               AXIS["(E)",east,
        <br>
                   ORDER[1],
        <br>
                   LENGTHUNIT["metre",1]],
        <br>
               AXIS["(N)",north,
        <br>
                   ORDER[2],
        <br>
                   LENGTHUNIT["metre",1]],
        <br>
           USAGE[
        <br>
               SCOPE["Cadastre, engineering survey, topographic mapping
        (large and medium scale)."],
        <br>
               AREA["Israel - onshore; Palestine Territory - onshore."],
        <br>
               BBOX[29.45,34.17,33.28,35.69]],
        <br>
           ID["EPSG",2039]]
        <br>
        Data axis to CRS axis mapping: 1,2
        <br>
        Origin = (202245.240786847687559,421915.720555976789910)
        <br>
        Pixel Size = (0.125000000000000,-0.125000000000000)
        <br>
        Metadata:
        <br>
         AREA_OR_POINT=Area
        <br>
        Image Structure Metadata:
        <br>
         INTERLEAVE=PIXEL
        <br>
        Corner Coordinates:
        <br>
        Upper Left  (  202245.241,  421915.721) ( 35d 1'32.11"E, 29d53'
        7.03"N)
        <br>
        Lower Left  (  202245.241,  418790.721) ( 35d 1'32.29"E,
        29d51'25.54"N)
        <br>
        Upper Right (  205370.241,  421915.721) ( 35d 3'28.57"E, 29d53'
        7.17"N)
        <br>
        Lower Right (  205370.241,  418790.721) ( 35d 3'28.72"E,
        29d51'25.68"N)
        <br>
        Center      (  203807.741,  420353.221) ( 35d 2'30.42"E,
        29d52'16.36"N)
        <br>
        Band 1 Block=25000x1 Type=Byte, ColorInterp=Red
        <br>
        Band 2 Block=25000x1 Type=Byte, ColorInterp=Green
        <br>
        Band 3 Block=25000x1 Type=Byte, ColorInterp=Blue
        <br>
        Band 4 Block=25000x1 Type=Byte, ColorInterp=Undefined<br>
        <br>
      </span>and the listgeo output is also different:</p>
    <p><br>
    </p>
    <p><span style="font-family:monospace"><span
          style="color:#000000;background-color:#ffffff;">listgeo
          HiBar_21022022_A1b.tif  </span><br>
        Geotiff_Information:
        <br>
          Version: 1
        <br>
          Key_Revision: 1.0
        <br>
          Tagged_Information:
        <br>
             ModelTiepointTag (2,3):
        <br>
                0                 0                 0                 <br>
                202245.240786848  421915.720555977  0                 <br>
             ModelPixelScaleTag (1,3):
        <br>
                0.125             0.125             0                 <br>
             End_Of_Tags.
        <br>
          Keyed_Information:
        <br>
             GTModelTypeGeoKey (Short,1): ModelTypeProjected
        <br>
             GTRasterTypeGeoKey (Short,1): RasterPixelIsArea
        <br>
             GTCitationGeoKey (Ascii,30): "Israel 1993 / Israeli TM
        Grid"
        <br>
             GeogCitationGeoKey (Ascii,12): "Israel 1993"
        <br>
             GeogAngularUnitsGeoKey (Short,1): Angular_Degree
        <br>
             ProjectedCSTypeGeoKey (Short,1): Code-2039 (Israel 1993 /
        Israeli TM Grid)
        <br>
             ProjLinearUnitsGeoKey (Short,1): Linear_Meter
        <br>
             End_Of_Keys.
        <br>
          End_Of_Geotiff.
        <br>
        <br>
        PCS = 2039 (Israel 1993 / Israeli TM Grid)
        <br>
        Projection = 18204 (Israeli TM)
        <br>
        Projection Method: CT_TransverseMercator
        <br>
          ProjNatOriginLatGeoKey: 31.734394 ( 31d44' 3.82"N)
        <br>
          ProjNatOriginLongGeoKey: 35.204517 ( 35d12'16.26"E)
        <br>
          ProjScaleAtNatOriginGeoKey: 1.000007
        <br>
          ProjFalseEastingGeoKey: 219529.584000 m
        <br>
          ProjFalseNorthingGeoKey: 626907.390000 m
        <br>
        GCS: 4141/Israel 1993
        <br>
        Datum: 6141/Israel 1993
        <br>
        Ellipsoid: 7019/GRS 1980 (6378137.00,6356752.31)
        <br>
        Prime Meridian: 8901/Greenwich (0.000000/  0d 0' 0.00"E)
        <br>
        Projection Linear Units: 9001/metre (1.000000m)
        <br>
        <br>
        Corner Coordinates:
        <br>
        Upper Left    (  202245.241,  421915.721)  ( 35d 1'32.11"E,
        29d53' 7.03"N)
        <br>
        Lower Left    (  202245.241,  418790.721)  ( 35d 1'32.29"E,
        29d51'25.54"N)
        <br>
        Upper Right   (  205370.241,  421915.721)  ( 35d 3'28.57"E,
        29d53' 7.17"N)
        <br>
        Lower Right   (  205370.241,  418790.721)  ( 35d 3'28.72"E,
        29d51'25.68"N)
        <br>
        Center        (  203807.741,  420353.221)  ( 35d 2'30.42"E,
        29d52'16.36"N)<br>
        <br>
        <br>
      </span></p>
    <p>So I guess that solves the problem, allowing for reprojection,
      and mapping together with other datasets.</p>
    <p>Thanks for you help (spot on, as always!)</p>
    <p><span style="font-family:monospace"><br>
      </span></p>
    <p><span style="font-family:monospace"><br>
      </span></p>
    <blockquote type="cite"
      cite="mid:a17513cc-3def-350e-807a-718e898eb94d@spatialys.com">
      <p>You likely need to gdal_translate -a_srs EPSG:2039 to do
        something useful with that file, and report to the data producer
        that the CRS encoding is broken</p>
      <p><br>
      </p>
      <div class="moz-cite-prefix">Le 08/03/2023 à 13:18, Micha Silver a
        écrit :<br>
      </div>
      <blockquote type="cite"
        cite="mid:a8073719-7e8b-af6a-55be-6ecf558b4256@gmail.com">
        <meta http-equiv="Content-Type" content="text/html;
          charset=UTF-8">
        <p>Hi Even:<br>
          <span style="font-family:monospace"><span
              style="color:#000000;background-color:#ffffff;"> </span></span></p>
        <p><span style="font-family:monospace"><span
              style="color:#000000;background-color:#ffffff;"><br>
            </span></span></p>
        <p><span style="color:#000000;background-color:#ffffff;">Here's
            the full gdalinfo, with the reported CRS:</span></p>
        <p><span style="font-family:monospace"><span
              style="color:#000000;background-color:#ffffff;"><br>
            </span></span></p>
        <p><span style="font-family:monospace"><span
              style="color:#000000;background-color:#ffffff;">gdalinfo
              HiBar_21022022_A1.tif </span><br>
            Driver: GTiff/GeoTIFF <br>
            Files: HiBar_21022022_A1.tif <br>
                  HiBar_21022022_A1.tif.aux.xml <br>
            Size is 25000, 25000 <br>
            Coordinate System is: <br>
            PROJCRS["Israel 1993 / Israeli TM Grid", <br>
               BASEGEOGCRS["WGS 84", <br>
                   DATUM["World Geodetic System 1984", <br>
                       ELLIPSOID["WGS 84",6378137,298.257223563, <br>
                           LENGTHUNIT["metre",1, <br>
                               ID["EPSG",9001]]]], <br>
                   PRIMEM["Greenwich",0, <br>
                       ANGLEUNIT["degree",0.0174532925199433, <br>
                           ID["EPSG",9122]]]], <br>
               CONVERSION["unnamed", <br>
                   METHOD["unnamed"]], <br>
               CS[Cartesian,2], <br>
                   AXIS["(E)",east, <br>
                       ORDER[1], <br>
                       LENGTHUNIT["metre",1, <br>
                           ID["EPSG",9001]]], <br>
                   AXIS["(N)",north, <br>
                       ORDER[2], <br>
                       LENGTHUNIT["metre",1, <br>
                           ID["EPSG",9001]]]] <br>
            Data axis to CRS axis mapping: 1,2 <br>
            Origin = (202245.240786847687559,421915.720555976789910) <br>
            Pixel Size = (0.125000000000000,-0.125000000000000) <br>
            Metadata: <br>
             AREA_OR_POINT=Area <br>
            Image Structure Metadata: <br>
             INTERLEAVE=PIXEL <br>
            Corner Coordinates: <br>
            ERROR 1: No inverse operation <br>
            Upper Left  (  202245.241,  421915.721)  <br>
            ERROR 1: No inverse operation <br>
            Lower Left  (  202245.241,  418790.721)  <br>
            ERROR 1: No inverse operation <br>
            Upper Right (  205370.241,  421915.721)  <br>
            ERROR 1: No inverse operation <br>
            Lower Right (  205370.241,  418790.721)  <br>
            ERROR 1: No inverse operation <br>
            Center      (  203807.741,  420353.221) <br>
            <br>
          </span>and proj version:<span style="font-family:monospace"><br>
          </span></p>
        <p><span style="font-family:monospace"><br>
          </span><span style="font-family:monospace"><span
              style="color:#000000;background-color:#ffffff;"></span></span></p>
        <p><span style="font-family:monospace"><span
              style="color:#000000;background-color:#ffffff;">proj </span><br>
            Rel. 9.1.1, December 1st, 2022</span></p>
        <p><span style="font-family:monospace"><br>
          </span></p>
        <p>(a newly installed debian 12)<span
            style="font-family:monospace"><br>
          </span></p>
        <p><br>
        </p>
        <p>Thanks,</p>
        <p>Micha</p>
        <p><span style="font-family:monospace"><br>
          </span></p>
        <div class="moz-cite-prefix">On 08/03/2023 13:47, Even Rouault
          wrote:<br>
        </div>
        <blockquote type="cite"
          cite="mid:ec6ceb21-9995-6036-339b-d31d7d42e264@spatialys.com">
          <meta http-equiv="Content-Type" content="text/html;
            charset=UTF-8">
          <p>Micha,</p>
          <p><br>
          </p>
          <p>which CRS is reported and which PROJ version do you use ?
            It is presumably one projection method for which PROJ only
            implements the forward conversion, that is from geographic
            to projected coordinates, but not the reverse way</p>
          <p><br>
          </p>
          <p>Even<br>
          </p>
          <p><br>
          </p>
          <div class="moz-cite-prefix">Le 08/03/2023 à 09:37, Micha
            Silver a écrit :<br>
          </div>
          <blockquote type="cite"
            cite="mid:49eb2124-9d86-df3f-ae41-cfc5eacfff20@gmail.com">
            <meta http-equiv="content-type" content="text/html;
              charset=UTF-8">
            <style id="bidiui-paragraph-margins" type="text/css">body p { margin-bottom: 0cm; margin-top: 0pt; }</style>
            <p>I received some Geotiff files, and gdalinfo shows:</p>
            <p><br>
            </p>
            <p><span style="font-family:monospace"><span
                  style="color:#000000;background-color:#ffffff;">Corner
                  Coordinates: </span><br>
                ERROR 1: No inverse operation <br>
                Upper Left  (  205370.241,  418790.721)  <br>
                ERROR 1: No inverse operation <br>
                Lower Left  (  205370.241,  415665.721)  <br>
                ERROR 1: No inverse operation <br>
                Upper Right (  206198.866,  418790.721)  <br>
                ERROR 1: No inverse operation <br>
                Lower Right (  206198.866,  415665.721)  <br>
                ERROR 1: No inverse operation <br>
                Center      (  205784.553,  417228.221) <br>
              </span><br>
              What does that mean?</p>
            <p><span style="font-family:monospace"><br>
              </span></p>
            <p><span style="font-family:monospace"><span
                  style="color:#000000;background-color:#ffffff;">gdalinfo
                  --version </span><br>
                GDAL 3.6.2, released 2023/01/02<br>
                <br>
              </span>Thanks</p>
            <p><br>
            </p>
            <pre class="moz-signature" cols="72">-- 
Micha Silver
Remote Sensing Lab, Sde Boker
Ben Gurion University
+972-523-665918</pre>
            <br>
            <fieldset class="moz-mime-attachment-header"></fieldset>
            <pre class="moz-quote-pre" wrap="">_______________________________________________
gdal-dev mailing list
<a class="moz-txt-link-abbreviated moz-txt-link-freetext" href="mailto:gdal-dev@lists.osgeo.org" moz-do-not-send="true">gdal-dev@lists.osgeo.org</a>
<a class="moz-txt-link-freetext" href="https://lists.osgeo.org/mailman/listinfo/gdal-dev" moz-do-not-send="true">https://lists.osgeo.org/mailman/listinfo/gdal-dev</a>
</pre>
          </blockquote>
          <pre class="moz-signature" cols="72">-- 
<a class="moz-txt-link-freetext" href="http://www.spatialys.com" moz-do-not-send="true">http://www.spatialys.com</a>
My software is free, but my time generally not.</pre>
        </blockquote>
        <pre class="moz-signature" cols="72">-- 
Micha Silver
Remote Sensing Lab, Sde Boker
Ben Gurion University
+972-523-665918</pre>
      </blockquote>
      <pre class="moz-signature" cols="72">-- 
<a class="moz-txt-link-freetext" href="http://www.spatialys.com" moz-do-not-send="true">http://www.spatialys.com</a>
My software is free, but my time generally not.</pre>
    </blockquote>
    <pre class="moz-signature" cols="72">-- 
Micha Silver
Remote Sensing Lab, Sde Boker
Ben Gurion University
+972-523-665918</pre>
  </body>
</html>