MCPcopy
hub / github.com/google/earthengine-api / getAlgorithms

Function getAlgorithms

python/ee/data.py:1420–1456  ·  view source on GitHub ↗

Get the list of algorithms. Returns: The dictionary of algorithms. Each algorithm is a dictionary containing the following fields: "description" - (string) A text description of the algorithm. "returns" - (string) The return type of the algorithm. "args" - An array

()

Source from the content-addressed store, hash-verified

1418 return f'{title_base_url}/{version}/{docid}:getFeatures'
1419
1420def getAlgorithms() -> Any:
1421 """Get the list of algorithms.
1422
1423 Returns:
1424 The dictionary of algorithms. Each algorithm is a dictionary containing
1425 the following fields:
1426 "description" - (string) A text description of the algorithm.
1427 "returns" - (string) The return type of the algorithm.
1428 "args" - An array of arguments. Each argument specifies the following:
1429 "name" - (string) The name of the argument.
1430 "description" - (string) A text description of the argument.
1431 "type" - (string) The type of the argument.
1432 "optional" - (boolean) Whether the argument is optional or not.
1433 "default" - A representation of the default value if the argument
1434 is not specified.
1435 """
1436 try:
1437 call = (
1438 _get_cloud_projects()
1439 .algorithms()
1440 .list(parent=_get_projects_path(), prettyPrint=False)
1441 )
1442 except TypeError:
1443 call = (
1444 _get_cloud_projects()
1445 .algorithms()
1446 .list(project=_get_projects_path(), prettyPrint=False)
1447 )
1448
1449 def inspect(response):
1450 if _INIT_MESSAGE_HEADER in response:
1451 print(
1452 '*** Earth Engine ***',
1453 response[_INIT_MESSAGE_HEADER],
1454 file=sys.stderr)
1455 call.add_response_callback(inspect)
1456 return _cloud_api_utils.convert_algorithms(_execute_cloud_call(call))
1457
1458
1459@_utils.accept_opt_prefix('opt_path', 'opt_force', 'opt_properties')

Callers

nothing calls this directly

Calls 5

_get_cloud_projectsFunction · 0.85
_get_projects_pathFunction · 0.85
_execute_cloud_callFunction · 0.85
listMethod · 0.80
algorithmsMethod · 0.80

Tested by

no test coverage detected