# C403 Lab: Choose and Access a Dataset for a Stated Purpose

> The hands-on lab of the C403 datasets course: write down a purpose, shortlist public egocentric datasets, read each one's licence tag and access gate through the Hugging Face API, read the card itself, check the paper, code and body-model licences, measure the repository before downloading, sample it, count it yourself and record the decision. Every command is as the Hugging Face documentation or client source gives it, and was run on the example datasets.

Page: https://egocam.ai/university/c403/lab/

This lab takes one purpose from a sentence to a recorded decision about which dataset to use and on what terms. It uses the Hugging Face Hub's public API and its Python client, `huggingface_hub`, because most 2025–2026 egocentric releases are hosted there. Datasets outside Hugging Face, such as Ego4D, are covered in step 6.

Every command below is copied from the Hugging Face documentation or follows the documented form of the `huggingface_hub` client, and each was run on the example datasets on 2026-11-08; the source is linked at each step. Square brackets mark values you fill in. The outputs shown are what the API returned on that date: terms change, so run the commands yourself before you rely on them.

Work through [Lessons 1 to 4](https://egocam.ai/university/c403/) first, and keep the [checklist](https://egocam.ai/university/c403/checklist/) next to you. Nothing in this lab is legal advice: it collects what the terms say, so that you, or counsel, can decide.

## Step 1: Write the purpose down

Write one paragraph that answers four questions. Every later step checks a dataset against it.

1. **Use.** Research only, or will the model, its outputs or the data end up in a product? Will you redistribute the data or a converted copy?
2. **Labels.** What must the data carry: video only, camera poses, 3D hand keypoints, body pose, language, actions?
3. **Capture.** How close must it be to your own rig: stereo or more on the head, wrist views, a handheld gripper?
4. **Budget.** How much storage and download time can you spend, and do you need it this week (a manual review can take days)?

The worked example in this lab: *a commercial model that predicts 3D hand trajectories from head-worn video, in homes and workplaces; we will not redistribute the data.*

## Step 2: Shortlist from the field guide

Start from the [Pick by task](https://egocam.ai/datasets/datasets-compared/#pick-by-task) table and the section page it points to, and copy each candidate's data licence and access from the [licences table](https://egocam.ai/datasets/licences-and-access/#licences-and-gates-compared). For the example, the robot-learning and gripper rows give a shortlist of five Hugging Face repositories, each of which the field guide describes:

| Candidate | Why it is on the list |
|---|---|
| `genrobot2025/Gen-HumanEgo` | Multi-camera head rig, 3D hand keypoints and MANO parameters per hand |
| `builddotai/Egocentric-10K` | Large factory corpus (hours are a card claim), monocular, no hand labels |
| `simple-world-lab/HiFi-UMI-2K` | Head stereo plus wrist views, both hands in one world frame, glove-like grippers |
| `projectaria/Nymeria` | Head and wrist Aria devices, full-body motion |
| `IPEC-COMMUNITY/FastUMI_100k_lerobot` | Handheld-gripper trajectories in LeRobot format |

EgoDex would fit the labels, but it is downloaded from Apple's repository, not Hugging Face, and its CC BY-NC-ND terms rule out commercial training ([Egocentric Datasets for Robot Learning](https://egocam.ai/datasets/robot-learning-datasets/#egodex-hand-poses-tracked-at-recording-time)).

## Step 3: Read the licence tag and the gate through the API

Install the client, as the [hf CLI guide](https://huggingface.co/docs/huggingface_hub/guides/cli) gives it:

```bash
pip install -U "huggingface_hub"
```

`HfApi.dataset_info` calls the Hub's `/api/datasets/{repo_id}` endpoint. Its `expand` argument limits the reply to the properties you list, among them `"gated"`, `"cardData"` and `"tags"` (the [`dataset_info` docstring](https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/hf_api.py)). Save this as `check_licence.py`:

```python

from huggingface_hub import HfApi

api = HfApi()
for repo_id in sys.argv[1:]:
    info = api.dataset_info(repo_id, expand=["gated", "cardData", "tags"])
    card = info.card_data.to_dict() if info.card_data else {}
    print(repo_id)
    print("  gated:        ", info.gated)
    print("  license:      ", card.get("license"))
    print("  license_name: ", card.get("license_name"))
    print("  license_link: ", card.get("license_link"))
    print("  gate fields:  ", list((card.get("extra_gated_fields") or {}).keys()))
```

Run it on the shortlist. No account is needed:

```bash
python check_licence.py genrobot2025/Gen-HumanEgo builddotai/Egocentric-10K \
    simple-world-lab/HiFi-UMI-2K projectaria/Nymeria IPEC-COMMUNITY/FastUMI_100k_lerobot
```

The same reply is available without Python, for example `curl -s "https://huggingface.co/api/datasets/projectaria/Nymeria?expand=gated&expand=cardData"`.

**You should see**, for the example on 2026-11-08:

| Repository | `gated` | `license` | Gate form fields |
|---|---|---|---|
| Gen-HumanEgo | `auto` | `cc-by-sa-4.0` | organisation, intended use, a description of intended use |
| Egocentric-10K | `auto` | `apache-2.0` | first and last name, affiliation, email, phone number, country |
| HiFi-UMI-2K | `False` | `cc-by-4.0` | none |
| Nymeria | `False` | `cc-by-nc-4.0` | none |
| FastUMI 100K | `False` | none | none |

`gated` is `False`, `"auto"` or `"manual"`, as the client's `DatasetInfo` documents it. Nymeria leaves the shortlist here: CC BY-NC forbids use primarily intended for commercial advantage, however open the download.

**If it fails:** a `RepositoryNotFoundError` means a wrong `repo_id` or a private repository. A `license` of `other` or none is not an answer: go to step 4.

## Step 4: Read the card itself

The tag is not the whole licence ([Lesson 4](https://egocam.ai/university/c403/lesson-4-licences-and-access/#traps-in-the-licence-tag)). Download each card and search it. `hf_hub_download` with `repo_type="dataset"` is the form the Hub's [downloading guide](https://huggingface.co/docs/hub/datasets-downloading) uses; the cards of the example gated repositories downloaded without a token. Save as `read_card.py`:

```python

from huggingface_hub import hf_hub_download

path = hf_hub_download(sys.argv[1], "README.md", repo_type="dataset")
for n, line in enumerate(open(path, encoding="utf-8"), 1):
    if any(w in line.lower() for w in ("licen", "commercial", "consent", "hours", "mano", "smpl")):
        print(n, line.rstrip())
```

```bash
python read_card.py IPEC-COMMUNITY/FastUMI_100k_lerobot
python read_card.py genrobot2025/Gen-HumanEgo
```

**You should see** FastUMI's README state that the dataset is released under the Apache-2.0 License, although its metadata carries no tag; and Gen-HumanEgo's card list "3D hand keypoints, MANO parameters, and full hand geometry" among its labels.

**Write down** the exact licence sentence and its line, the consent statement if there is one, and every hour figure, marked as the card's claim.

## Step 5: Separate the licences on each release

For each remaining candidate, fill in four lines ([Lesson 4](https://egocam.ai/university/c403/lesson-4-licences-and-access/#three-licences-on-one-release)):

- **Data licence:** from the card or the licence page (steps 3 and 4).
- **Paper licence:** from the arXiv or journal page. It covers the paper only; note it so nobody confuses the two.
- **Code licence:** from the repository of the loaders. It does not cover the data.
- **Body-model licence:** if any labels are MANO, SMPL or SMPL-X parameters, the model's own licence applies, and MANO's is non-commercial ([Body-model licences](https://egocam.ai/datasets/licences-and-access/#body-model-licences-mano-smpl-and-smpl-x)).

For the example, Gen-HumanEgo's data licence (CC BY-SA 4.0) allows commercial use and asks that adapted versions you distribute stay CC BY-SA, but its MANO parameters bring in the MANO licence. Which label fields you may use is a question for counsel, written down as such. Egocentric-10K allows commercial training under Apache-2.0 but carries no hand labels, so it fits a pretraining stage, not the label requirement.

> **Diagram:** Top: the parts of one dataset release and which licence governs each, with an example from this page. A paper's licence covers the paper (Ego-1K's is CC BY 4.0) and a repository's covers its code (Ego4D's is MIT); training is governed by the data licence (Ego-1K: FAIR Noncommercial), plus the body model's licence for MANO, SMPL or SMPL-X labels (HOT3D's hand files are CC BY-NC-SA) and each source's licence in a merged corpus (OpenEgo). Bottom: the access route and the licence are independent. Some datasets download with no form yet forbid commercial training (Ego-1K, Nymeria, EgoDex, the Aria agreements), while others ask for a form or review and allow it (Egocentric-10K/100K, Gen-HumanEgo, Lightwheel by its licence name, the Mundo AI sample). Licences as stated on each card or agreement, read 2026-11-07; not legal advice.

## Step 6: Pass the gate

Requesting access to a gated Hugging Face dataset "can only be done from your browser" ([Gated datasets](https://huggingface.co/docs/hub/datasets-gated)). Open the dataset page while logged in, fill the form completely, and submit. With `gated: auto` access is granted at once; with `gated: manual` the maintainers decide, which can take days.

To download a gated dataset from a script, log in once, as the same page shows:

```bash
hf auth login
```

Then check that your token has access before a long job. `HfApi.auth_check` raises `GatedRepoError` if the repository is gated and you are not authorised (its [docstring](https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/hf_api.py)):

```python
from huggingface_hub import HfApi
from huggingface_hub.errors import GatedRepoError

try:
    HfApi().auth_check("[REPO_ID]", repo_type="dataset")
    print("access OK")
except GatedRepoError:
    print("no access yet")  # request it in the browser
```

**You should see**, without logging in, `no access yet` for `builddotai/Egocentric-10K` and `access OK` for `simple-world-lab/HiFi-UMI-2K`.

**Outside Hugging Face:** Ego4D and Ego-Exo4D each need their own signed agreement, then about 48 hours for AWS credentials, then the `ego4d` or `egoexo` CLI ([Landmark Datasets, getting the data](https://egocam.ai/datasets/landmark-datasets/#getting-the-data)). The Ego4D docs note that "once approved your access credentials will expire in 14 days" ([Ego4D: Start Here](https://ego4d-data.org/docs/start-here/)), so plan the download before you request it.

## Step 7: Measure before you download

The Hub's [OpenAPI reference](https://huggingface.co/spaces/huggingface/openapi) documents `GET /api/datasets/{namespace}/{repo}/treesize/{rev}/{path}`, which returns the total size in bytes of a repository at a revision:

```bash
curl -s https://huggingface.co/api/datasets/[NAMESPACE]/[REPO]/treesize/main
```

**You should see**, for `genrobot2025/Gen-EgoData`, `{"path":"/","size":47636792863}`, about 47.6 GB, which matches the 47.6 GB the field guide gives for that sample.

For a file-by-file list, the [hf CLI guide](https://huggingface.co/docs/huggingface_hub/guides/cli) documents a dry run that downloads nothing:

```bash
hf download [REPO_ID] --repo-type dataset --dry-run
```

**You should see** a line such as `[dry-run] Will download 502 files (out of 502) totalling 47.6G.`, followed by each file and its size. Compare the total with the card's stated size; a repository that holds two formats of the same episodes is about twice one copy ([Lesson 3](https://egocam.ai/university/c403/lesson-3-reading-the-numbers/#two-formats-of-the-same-data)).

## Step 8: Download a sample and count it yourself

Download only a slice first, with the `--include` patterns the CLI guide documents, and with `--dry-run` again until the slice is the size you want:

```bash
hf download [REPO_ID] --repo-type dataset --include "[PATTERN]" --local-dir [FOLDER]
```

Then count what you have, instead of trusting the headline ([Lesson 3](https://egocam.ai/university/c403/lesson-3-reading-the-numbers/#count-it-yourself)). For a LeRobot dataset, `meta/info.json` holds `total_episodes`, `total_frames` and `fps` ([lerobot `dataset_metadata.py`](https://github.com/huggingface/lerobot/blob/main/src/lerobot/datasets/dataset_metadata.py)). Save as `count.py`:

```python

from huggingface_hub import hf_hub_download

info = json.load(open(hf_hub_download(sys.argv[1], "meta/info.json", repo_type="dataset")))
print("codebase_version:", info.get("codebase_version"))
print("episodes:", info["total_episodes"], "frames:", info["total_frames"], "fps:", info["fps"])
print("recorded hours:", round(info["total_frames"] / info["fps"] / 3600, 1))
```

```bash
python count.py lerobot/umi_cup_in_the_wild
```

**You should see** `codebase_version: v3.0`, `episodes: 1447 frames: 699432 fps: 10` and `recorded hours: 19.4`, matching the counts on [Open Handheld-Gripper Datasets](https://egocam.ai/umi/gripper-datasets/). For MCAP or WebDataset releases, count from the per-file metadata the card documents.

Then open a few episodes and look: are the labels you need present and plausible, do confidence or validity fields exist, and does the camera view resemble your rig ([Lesson 2](https://egocam.ai/university/c403/lesson-2-how-they-were-captured/))?

## Step 9: Record the decision

Fill in the sign-off section of the [checklist](https://egocam.ai/university/c403/checklist/) for each dataset you keep, and keep it with your training configuration:

- repository and revision (commit) you downloaded. A Hub repository is a Git repository, and its files, card and licence text can change after you check them; some releases sit in mutable storage, where the current file listing, not a fixed version, defines what is published ([Lesson 3](https://egocam.ai/university/c403/lesson-3-reading-the-numbers/#card-claims-and-planned-hours)). The commit hash fixes exactly which version your decision covers;
- data licence as stated, with the exact sentence, plus paper, code and body-model licences;
- gate type, the date access was granted, and any agreement you signed;
- the card's hour claim and your own count;
- what the decision rests on, and anything left for counsel.

The [prompts page](https://egocam.ai/university/c403/prompts/) has a prompt that drafts this record from your notes.

## Sources

- Hugging Face Hub documentation: [Gated datasets](https://huggingface.co/docs/hub/datasets-gated), [Downloading datasets](https://huggingface.co/docs/hub/datasets-downloading), [OpenAPI reference](https://huggingface.co/spaces/huggingface/openapi), [hf CLI guide](https://huggingface.co/docs/huggingface_hub/guides/cli).
- `huggingface_hub` source, [github.com/huggingface/huggingface_hub](https://github.com/huggingface/huggingface_hub) (commit `fd5dccb`, version 2.4.0): `HfApi.dataset_info`, `DatasetInfo`, `HfApi.auth_check`, `hf_hub_download`.
- LeRobot source, [github.com/huggingface/lerobot](https://github.com/huggingface/lerobot) (commit `d490e47`): `dataset_metadata.py`.
- Dataset cards on Hugging Face: [Gen-HumanEgo](https://huggingface.co/datasets/genrobot2025/Gen-HumanEgo), [Egocentric-10K](https://huggingface.co/datasets/builddotai/Egocentric-10K), [HiFi-UMI-2K](https://huggingface.co/datasets/simple-world-lab/HiFi-UMI-2K), [Nymeria](https://huggingface.co/datasets/projectaria/Nymeria), [FastUMI 100K](https://huggingface.co/datasets/IPEC-COMMUNITY/FastUMI_100k_lerobot), [Gen-EgoData](https://huggingface.co/datasets/genrobot2025/Gen-EgoData), [umi_cup_in_the_wild](https://huggingface.co/datasets/lerobot/umi_cup_in_the_wild).
- [Ego4D: Start Here](https://ego4d-data.org/docs/start-here/).
- Field guide: [Dataset Licences and Access](https://egocam.ai/datasets/licences-and-access/), [Egocentric Datasets Compared](https://egocam.ai/datasets/datasets-compared/), [Egocentric Datasets for Robot Learning](https://egocam.ai/datasets/robot-learning-datasets/), [Landmark Datasets](https://egocam.ai/datasets/landmark-datasets/), [Open Handheld-Gripper Datasets](https://egocam.ai/umi/gripper-datasets/).
