<!DOCTYPE html>
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body>
    <p><br>
    </p>
    <div class="moz-cite-prefix">Le 13/01/2025 à 23:36, afernandez via
      gdal-dev a écrit :<br>
    </div>
    <blockquote type="cite"
      cite="mid:60dd785d2a744.fd524c120f669@odyhpc.com">
      <meta http-equiv="content-type" content="text/html; charset=UTF-8">
      <div>
        <div dir="auto" id="compose-body-wrapper">
          <div dir="auto">
            <div dir="auto">Hello,</div>
            <div dir="auto">The following snippet works fine</div>
            <div dir="auto">#        epsg = 54030            </div>
            <div dir="auto">        epsg = 4326            </div>
            <div dir="auto">        srs = osr.SpatialReference()</div>
            <div dir="auto">        srs.ImportFromEPSG(epsg)</div>
            <div dir="auto">However, and when I switch epsg to 54030
              (which I believe it's the value for the Robinson
              projection), it generates the error:</div>
            <div dir="auto">  File
              "/usr/lib/python3/dist-packages/osgeo/osr.py", line 772,
              in ImportFromEPSG</div>
            <div dir="auto">    return
              _osr.SpatialReference_ImportFromEPSG(self, *args)</div>
            <div dir="auto">RuntimeError: PROJ:
              proj_create_from_database: crs not found</div>
          </div>
        </div>
      </div>
    </blockquote>
    <p>54030 is not a EPSG CRS but a ESRI one, so use
      srs.SetFromUserInput("ESRI:54030")</p>
    <p>Even</p>
    <p>-- </p>
    <pre class="moz-signature" cols="72"><a class="moz-txt-link-freetext" href="http://www.spatialys.com">http://www.spatialys.com</a>
My software is free, but my time generally not.
Butcher of all kinds of standards, open or closed formats. At the end, this is just about bytes.</pre>
  </body>
</html>