---
title: "Dataset.find"
description: "Find a specific datapoint by ID across one or more collections in this dataset."
image: "https://tilebox.com/images/tilebox-docs-social-preview.png"
---

> Documentation Index
> Fetch the complete documentation index at: https://tilebox.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Dataset.find

import { Fragment } from "astro/jsx-runtime";

import ApiReference from "@docs/components/ApiReference.astro";

import ParamField from "@docs/components/ParamField.astro";

```python
def Dataset.find(
    datapoint_id: str | UUID,
    collections: list[str] | list[UUID] | list[Collection] | list[CollectionInfo] | list[CollectionClient] | None = None,
    skip_data: bool = False,
) -> xarray.Dataset
```

Find a specific datapoint by ID across one or more collections in this dataset.

If `collections` is not provided, all collections in the dataset are searched.

## Parameters

**datapoint_id**

type: str | UUID

The ID of the datapoint to find.

**collections**

type: list[str | UUID | Collection | CollectionInfo | CollectionClient] | None

Optional collection scope for the lookup.

Supported values include collection names, collection IDs, and collection objects. If omitted or set to `None`, all collections in the dataset are searched.

**skip_data**

type: bool

If `True`, only required datapoint fields are returned (`time`, `id`, `ingestion_time`). Defaults to `False`.

## Returns

An [`xarray.Dataset`](/docs/sdks/python/xarray) containing the requested datapoint.

Since it returns only a single datapoint, the output dataset does not include a `time` dimension.

## Errors

**ValueError**

type: "Invalid

is not a valid UUID">
Raised when `datapoint_id` is not a valid UUID.

**ValueError**

type: "Collection

not found in dataset <dataset>">
Raised when one or more collection names do not exist in the dataset.

**ValueError**

type: "Collection

is not part of the dataset <dataset>">
Raised when one or more provided collection IDs/objects are not part of the dataset.

**NotFoundError**

type: "No

">
Raised when the datapoint cannot be found in the selected collections.

<h2 id="request-example">Usage example</h2>

```python
# search all collections in the dataset
datapoint = dataset.find(
    "0186d6b6-66cc-fcfd-91df-bbbff72499c3"
)

# search specific collections only
datapoint = dataset.find(
    "0186d6b6-66cc-fcfd-91df-bbbff72499c3",
    collections=["S2A_S2MSI2A", "S2B_S2MSI2A"],
)

# check if a datapoint exists
from tilebox.datasets.sync.dataset import (
    NotFoundError,
)

try:
    dataset.find(
        "0186d6b6-66cc-fcfd-91df-bbbff72499c3",
        collections=["S2A_S2MSI2A"],
        skip_data=True,
    )
    exists = True
except NotFoundError:
    exists = False
```

Source: https://tilebox.com/docs/api-reference/python/tilebox.datasets/Dataset.find/index.mdx
