Stay organized with collections Save and categorize content based on your preferences.
This quickstart will give you an interactive introduction to visualizing and analyzing geospatial data with the Earth Engine Python interface.
Before you beginRegister or create a Google Cloud Project; you'll be prompted to complete the following steps. If you already have a project registered for Earth Engine access, skip to the next section.
Note: If you don't plan to keep the resources that you create in this procedure, create a project instead of selecting an existing project. After you finish these steps, you can delete the project, removing all resources owned by the project.
Jupyter notebooks allow you to use Earth Engine and explore results interactively. The quickest way to get started is with a notebook in Google Colab notebook. You can either
open a new notebookand copy the following code chunks into individual cells or use the prefilled
Earth Engine Python Quickstart notebook.
import ee import geemap.core as geemap
ee.Authenticate() ee.Initialize(project='PROJECT_ID')
jan_2023_climate = ( ee.ImageCollection('ECMWF/ERA5_LAND/MONTHLY_AGGR') .filterDate('2023-01', '2023-02') .first() ) jan_2023_climate
m = geemap.Map(center=[30, 0], zoom=2) vis_params = { 'bands': ['temperature_2m'], 'min': 229, 'max': 304, 'palette': 'inferno', } m.add_layer(jan_2023_climate, vis_params, 'Temperature (K)') m
cities = ee.FeatureCollection([ ee.Feature(ee.Geometry.Point(10.75, 59.91), {'city': 'Oslo'}), ee.Feature(ee.Geometry.Point(-118.24, 34.05), {'city': 'Los Angeles'}), ee.Feature(ee.Geometry.Point(103.83, 1.33), {'city': 'Singapore'}), ]) cities
m.add_layer(cities, name='Cities') m
%pip install -q --upgrade altair import altair as alt
city_climates = jan_2023_climate.reduceRegions(cities, ee.Reducer.first()) city_climates_dataframe = ee.data.computeFeatures( {'expression': city_climates, 'fileFormat': 'PANDAS_DATAFRAME'} ) city_climates_dataframe
alt.Chart(city_climates_dataframe).mark_bar(size=100).encode( alt.X('city:N', sort='y', axis=alt.Axis(labelAngle=0), title='City'), alt.Y('temperature_2m:Q', title='Temperature (K)'), tooltip=[ alt.Tooltip('city:N', title='City'), alt.Tooltip('temperature_2m:Q', title='Temperature (K)'), ], ).properties(title='January 2023 temperature for selected cities', width=500)
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-11-07 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-11-07 UTC."],[[["This quickstart provides an interactive introduction to visualizing and analyzing geospatial data using the Earth Engine Python interface within a Jupyter notebook environment like Google Colab."],["Users will learn to add both raster and vector data to an interactive map, visualizing climate data and city locations as examples."],["The guide demonstrates data extraction and charting by retrieving climate data for specific cities and creating a bar chart using the Altair library."],["Before starting, users need a Google Cloud Project registered for Earth Engine access, and the quickstart provides instructions for setting one up."],["Further learning resources on Earth Engine objects, processing environments, machine learning capabilities, and data export to BigQuery are linked at the end."]]],[]]
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4