import ee
ee.Authenticate()
myproject='ee-jrferrerparis'
ee.Initialize(project=myproject)5 Digital assets in Earth Engine
Google Earth Engine is a geospatial processing service that allow users to perform geospatial processing at scale. It is powered by Google Cloud Platform.
Earth engine has different APIs and client libraries that translate complex geospatial analyses to Earth Engine requests.
The Code Editor allows to run an interactive session using JavaScript.
Here I use the open source Python library in a local Python environment.
5.1 Initialise a session
First we import the ee module. The script requires setting up authentication and initialising the session with a valid project.
Read the detailed instructions here
5.2 Contributed assets
The main asset I will be using in Earth Engine is the map of the macrogroups potential distribution (Ferrer-Paris 2025).
The original map in Robinson projection could not be uploaded directly to Earth Engine due to an error processing the projection information (complaining about unknown parameters in WKT string).
As an alternative I reprojected my local copy of the map using this projection information:
gdalwarp -r near -co COMPRESS=DEFLATE \
-t_srs '+proj=cea +lat_ts=0 +lon_0=-80 +x_0=0 +y_0=0 +R=6371000 +units=m +no_defs +type=crs'\
IVC_NS_v7_270m_robin.tif IVC_NS_v7_270m_cea.tif
# NoData Value=65535This version of the map was successfully uploaded to the my project and is available for EE workflows as:
macrogroups=ee.Image('projects/{}/assets/IVC_NS_v7_270m_cea'.format(myproject))5.3 Third party assets
There are other third-party assets available in Earth Engine’s data catalog that are required for the RLE assessment. One is the collection of country boundaries used to define regions of interest.
countries=ee.FeatureCollection('USDOS/LSIB_SIMPLE/2017')The other one is the Global Forest Change dataset , see details in chapter 7:
gfc=ee.Image('UMD/hansen/global_forest_change_2024_v1_12')