Guest User

Untitled

a guest
Dec 13th, 2018
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.64 KB | None | 0 0
  1. import pyproj
  2.  
  3. def gcba_proj(x, y):
  4. """
  5. Converts x and y from Gauss Kruger projection to longitude and latitude coordinates system
  6.  
  7. Arg
  8. ---
  9. x: Longitud term.
  10. y: Latitud term.
  11.  
  12. Returns
  13. -------
  14. Tuple with longitude and latitude values. i.e: (-54.235, -38.245).
  15.  
  16. """
  17.  
  18. longitud = x
  19. latitud = y
  20.  
  21. bsas_proj = pyproj.Proj("""+proj=tmerc +lat_0=-34.6297166 +lon_0=-58.4627 +k=0.9999980000000001 +x_0=100000 +y_0=100000
  22. +ellps=intl +towgs84=-148,136,90,0,0,0,0 +units=m +no_defs""")
  23.  
  24. lola_proj = pyproj.Proj("+init=EPSG:4326")
  25.  
  26. return pyproj.transform(bsas_proj, dest_proj, longitud, latitud)
Add Comment
Please, Sign In to add comment