Client and Search

class ceda_datapoint.core.client.DataPointSearch(pystac_search: object, mappings: dict = None, search_terms: dict = None, meta: dict = None, parent_id: str = None)[source]

Search instance created upon searching using the client.

property items: dict[str, ceda_datapoint.core.item.DataPointItem]

Get the set of DataPointItem objects described by this search.

property assets: dict

Get the set of assets under each item in this search, returned as a set of nested dictionaries.

help() None[source]

Helper function - lists methods that can be utilised for this class

info() None[source]

Provide information about this search

open_dataset(id: str, mode: str = 'xarray', combine: bool = False, priority: list[str] = [], mappings: dict = None, **kwargs) Dataset[source]

Open a dataset directly from the search result

Parameters:
  • id – (str) The ID or index of the dataset in the resulting cluster.

  • mode – (str) The type of dataset to be returned, currently only Xarray is supported (0.4.X)

  • combine – (bool) Combine multiple datasets to a single dataset - not implemented (0.4.X)

  • priority – (list) Order by which to open a set of datasets.

collect_cloud_assets(mode: str = 'xarray', combine: bool = False, priority: list[str] = [], show_unreachable: bool = False, asset_mappings: dict = None, **kwargs) DataPointCluster[source]

Open a DataPointCluster object from the cloud assets for each item in this search.

Parameters:
  • mode – (str) The type of dataset to be returned, currently only Xarray is supported (0.4.X)

  • combine – (bool) Combine multiple datasets to a single dataset - not implemented (0.4.X)

  • priority – (list) Order by which to open a set of datasets.

  • show_unreachable – (bool) Show the hidden assets that DataPoint has determined are currently unreachable.

display_assets() None[source]

Display the number of assets attributed to each item in the itemset.

display_cloud_assets() None[source]

Display the cloud assets attributed to each item in the itemset.

class ceda_datapoint.core.client.DataPointClient(org: str = 'CEDA', url: str = None, hash_token: str = None, mappings: dict = None)[source]

Client for searching STAC collections, returns self-describing components at all points.

help() None[source]

Helper function - lists methods that can be utilised for this class

info() None[source]

Display information about this class object

list_query_terms(collection: str) list | None[source]

List the possible query terms for all or a particular collection.

display_query_terms(collection: str = None) None[source]

Display query terms for all collections or just a specific collection.

list_collections() list[source]

Return a list of the names of collections for this Client

display_collections()[source]

Display the list of collections with their descriptions

search(mappings: dict = None, **kwargs) DataPointSearch[source]

Perform a search operation, creates a DataPointSearch object which is also self-describing.