TransWikia.com

How to get the projection of ui.Map in Google Earth Engine?

Geographic Information Systems Asked by Andrei on December 11, 2020

I know it’s 3857, but I would really like to not hard-code it, only so that the script fails later when the GEE team decides to switch.
What I tried is to get the projection from a displayed image of a layer:

Map.layers().get(0).getEeObject().projection()

But it just returns 4326, which is obviously not the map’s, nor the displayed layer’s projection. It’s actually not even the image’s projection, but that’s another story.

Any other suggestions?

One Answer

Have you read the part about projections in the Earth Engine documentation yet?

Overall, everything displayed in the Code Editor is requested in EPSG:3857, however that does not mean that it's also saved on the server like that. It is only really important to assign a crs for some operations, like .reduceRegions() or Export. Everything else should get properly handled by the Earth Engine Framework.

Answered by JonasV on December 11, 2020

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP