matplotlib / matplotlib/basemap

rotpole projection to ESRI shape file

Offen
#306 1 Kommentar 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

Vorherrschende Sprache
Python
Sterne
817
Forks
395
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

Hi:

Does anyone know how to convert rotpole projection to ESRI format, to write data into a shape file?

I tried to do it using basemap.proj4string, and then pycrs or gdal, but there are some things missing from the proj4string...

I've added +ellps, but +o_proj=longlat +proj=ob_tran do not seem to be recognized...

Here is the proj4 I am trying to use:

+R=6370997.0 +lon_0=-97.0 +o_lat_p=42.5 +units=m +proj=ob_tran +o_lon_p=180.0 +o_proj=longlat +ellps=WGS84

pycrs complains that it does not know the specified name:

```
Traceback (most recent call last):
File "/Users/huziy/skynet2/RESCUE/skynet3_rech1/huziy/Netbeans Projects/Python/RPN/src/crcm5/mh_domains/show_domain_with_drainage_area.py", line 213, in
main()
File "/Users/huziy/skynet2/RESCUE/skynet3_rech1/huziy/Netbeans Projects/Python/RPN/src/application_properties.py", line 15, in wrapper
func(*args, **kwargs)
File "/Users/huziy/skynet2/RESCUE/skynet3_rech1/huziy/Netbeans Projects/Python/RPN/src/crcm5/mh_domains/show_domain_with_drainage_area.py", line 203, in main
crs = pycrs.parser.from_proj4(bmp.proj4string + " +ellps={}".format("WGS84"))
File "/Users/huziy/virtualenvs/py3.4/lib/python3.4/site-packages/pycrs/parser.py", line 565, in from_proj4
raise Exception("The specified projection name could not be found")
Exception: The specified projection name could not be found
```

Below is my test code (the pj=basemap.proj4string + " +ellps=WGS84"):

``` python
import pycrs
pj = "+R=6370997.0 +lon_0=-97.0 +o_lat_p=42.5 +units=m +proj=ob_tran +o_lon_p=180.0 +o_proj=longlat +ellps=WGS84"
crs = pycrs.parser.from_proj4(pj)
print(crs.to_esri_wkt())
```

Cheers

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Erste Schritte

  1. Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
  3. Forke das Repository und arbeite in einem Branch.
  4. Öffne einen Pull Request, der die Issue-Nummer nennt.

Rechercherichtung

Beginne damit, das bereitgestellte Python-Snippet auszuführen und Basemap's proj4string-Ausgabe zusammen mit den im Bericht erwähnten pycrs- und GDAL-Konvertierungspfaden zu prüfen. Das Issue nennt keine Basemap-Quelldatei und keinen Test; als erledigt würde die Aufgabe einen bestätigten Weg zur Verarbeitung dieser rotpole-Projektion in der ESRI-shapefile-Ausgabe oder eine dokumentierte Einschränkung erfordern, falls sie nicht unterstützt wird.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
python
Bereich
data-visualization
Issue-Typ
Feature
Schwierigkeit
5/5
Geschätzter Aufwand
Über eine Woche
Aktivitätsstatus
Veraltet
Klarheit
Muss geklärt werden
Anfängerfreundlichkeit
15/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.