would it be possible to have the CRS bounds in its original unit ?
See original GitHub issueLet’s assume I want to get the bounds of the projection ‘EPSG:3857’ in meters (unit of the 3857 projection)
In the current implementation of pyproj and with my little knowledge I would do the following :
from pyproj import CRS, Transformer
in_crs = CRS.from_epsg(4326)
out_crs = CRS.from_epsg(3857)
x_min, y_min, x_max, y_max = out_crs.area_of_use.bounds
proj = Transformer.from_crs(4326, 3857, always_xy=True)
bl = proj.transform(x_min, y_min)
tr = proj.transform(x_max, y_max)
that’s a lot of steps just to extract the bounds in the original proj unit. Would it be possible to add a method to retrieve the projection in its original unit ?
I would be happy to PR this very code in PR if you agree with this way of computing it.
maybe I’m foolish and there is already a way to retrieve the bounds…
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Overview of Coordinate Reference Systems (CRS) in R
Map coordinates of a point are computed from its ellipsoidal latitude and longitude by a standard formula known as a map projection. It...
Read more >What does 'projected bounds' and 'WGS84 bounds' mean in ...
The projected bounds is this area in the units and projection of the CRS you are interested in while WGS84 bounds are those...
Read more >Handling Spatial Projection & CRS - Data Carpentry
This layer contains the boundaries of all contiguous states in the U.S. Please note that these data have been modified and reprojected from...
Read more >7 Reprojecting geographic data - Geocomputation with R
Datasets without a specified CRS can cause problems: all geographic coordinates have a coordinate system and software can only make good decisions around ......
Read more >Coordinate Reference System and Spatial Projection - Earth Lab
Geographic CRS - The Good & The Less Good ... Geographic coordinate systems in decimal degrees are helpful when you need to locate...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
awesome ! thanks a lot
I have edited my answer on GIS.Stackexchange: https://gis.stackexchange.com/questions/390517/getting-projected-bounds-information-in-pyproj/392407#392407
let me know when it will be released !
How to get projected bounds with #810: