Skip to content

Instantly share code, notes, and snippets.

@jdbcode
Last active November 8, 2022 19:58
Show Gist options
  • Save jdbcode/1deab994fd3e4a3d15b64f5d49f0f605 to your computer and use it in GitHub Desktop.
Save jdbcode/1deab994fd3e4a3d15b64f5d49f0f605 to your computer and use it in GitHub Desktop.
ee-api-methods-list.ipynb
Display the source blob
Display the rendered blob
Raw
{
"nbformat": 4,
"nbformat_minor": 0,
"metadata": {
"colab": {
"provenance": [],
"collapsed_sections": [],
"include_colab_link": true
},
"kernelspec": {
"name": "python3",
"display_name": "Python 3"
}
},
"cells": [
{
"cell_type": "markdown",
"metadata": {
"id": "view-in-github",
"colab_type": "text"
},
"source": [
"<a href=\"https://colab.research.google.com/gist/jdbcode/1deab994fd3e4a3d15b64f5d49f0f605/ee-api-methods-list.ipynb\" target=\"_parent\"><img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/></a>"
]
},
{
"cell_type": "code",
"metadata": {
"id": "Xgw6CJMA5Esl"
},
"source": [
"import ee\n",
"ee.Authenticate()\n",
"ee.Initialize()"
],
"execution_count": null,
"outputs": []
},
{
"cell_type": "code",
"source": [
"objects = [\n",
" {'name': 'ee.Feature', 'object': ee.Feature(ee.Geometry.Point([-125, 45]))},\n",
" {'name': 'ee.Image', 'object': ee.Image.constant(1)},\n",
" {'name': 'ee.FeatureCollection', 'object': ee.FeatureCollection('...')},\n",
" {'name': 'ee.ImageCollection', 'object': ee.ImageCollection('...')},\n",
" {'name': 'ee.Filter', 'object': ee.Filter(ee.Filter.eq('',''))},\n",
" {'name': 'ee.Reducer', 'object': ee.Reducer.mean()},\n",
"]"
],
"metadata": {
"id": "rJ8PZQIKu8r3"
},
"execution_count": null,
"outputs": []
},
{
"cell_type": "code",
"source": [
"for obj in objects:\n",
" print(obj['name'])\n",
" methods = dir(obj['object'])\n",
" for thing in methods.copy():\n",
" if thing[0] is '_':\n",
" methods.remove(thing)\n",
"\n",
" print(methods)"
],
"metadata": {
"id": "FU9oNdlvvqTb"
},
"execution_count": null,
"outputs": []
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment