Aggregate Sequences Count
- async AsyncCogniteClient.sequences.aggregate_count(
- advanced_filter: Filter | dict[str, Any] | None = None,
- filter: SequenceFilter | dict[str, Any] | None = None,
Count of sequences matching the specified filters and search.
- Parameters:
advanced_filter (Filter | dict[str, Any] | None) – The filter to narrow down the sequences to count.
filter (SequenceFilter | dict[str, Any] | None) – The filter to narrow down sequences to count requiring exact match.
- Returns:
The number of sequences matching the specified filters and search.
- Return type:
int
Examples
Count the number of time series in your CDF project:
>>> from cognite.client import CogniteClient, AsyncCogniteClient >>> client = CogniteClient() >>> # async_client = AsyncCogniteClient() # another option >>> count = client.sequences.aggregate_count()
Count the number of sequences with external id prefixed with “mapping:” in your CDF project:
>>> from cognite.client.data_classes import filters >>> from cognite.client.data_classes.sequences import SequenceProperty >>> is_mapping = filters.Prefix(SequenceProperty.external_id, "mapping:") >>> count = client.sequences.aggregate_count(advanced_filter=is_mapping)