File size: 4,954 Bytes
b147e68
 
eec0a0e
 
 
 
 
 
 
 
 
 
 
b147e68
383eafb
 
 
e83c9cc
383eafb
e83c9cc
383eafb
e83c9cc
383eafb
c71274f
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
e83c9cc
 
 
383eafb
e83c9cc
 
 
383eafb
e83c9cc
383eafb
e83c9cc
383eafb
e83c9cc
383eafb
e83c9cc
 
 
 
 
 
383eafb
e83c9cc
383eafb
e83c9cc
383eafb
e83c9cc
 
 
 
 
 
 
383eafb
e83c9cc
383eafb
e83c9cc
383eafb
e83c9cc
383eafb
e83c9cc
383eafb
acf19f1
383eafb
 
 
 
 
 
 
 
 
 
 
acf19f1
383eafb
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
e83c9cc
383eafb
e83c9cc
383eafb
e83c9cc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
---
license: mit
language:
- en
tags:
- egocentric-video
- camera-pose
- visual-navigation
- semantic-annotations
- spatial-understanding
pretty_name: SpatialSemanticDataset
size_categories:
- 10K<n<100K
---

# SpatialSemanticDataset

SpatialSemanticDataset is a dataset of first-person walking videos annotated with camera poses and English semantic descriptions. It organizes annotations by scene and supports research on visual navigation, camera trajectory and language alignment, and descriptions of observations and intended actions.

The dataset covers **12,079 scenes from 3,188 videos across 9 source channels**. This repository contains the scene index and annotations. The source videos are hosted separately and can be located by their YouTube video IDs.

The data processing pipeline is maintained in a separate repository. [SpatialSemanticPipeline](https://github.com/monsterdie12138/SpatialSemanticPipeline)

## Annotation methodology

The accompanying pipeline uses TransNetV2 to detect scene boundaries in
source videos. It runs VGGT-Omega on overlapping video chunks to estimate
camera positions and orientations. The pipeline checks trajectory quality,
and the released pose CSVs include a `status` field. Rows marked `bad`
can contain missing pose values.

A vision-language model generates timestamped English annotations from
video clips. When trajectory-derived navigation hints are available, the
pipeline includes them in the prompt. Otherwise, it uses a prompt without
hints. Each annotation contains an `Observation` describing visible
content, a `Latent Thought` expressing the model's inference about intent
or reasoning, and an `Action` describing movement.

See [SpatialSemanticPipeline](https://github.com/monsterdie12138/SpatialSemanticPipeline)
for the implementation, configuration, and prompt templates.

## Repository layout

| Path | Contents |
| --- | --- |
| `metadata.csv` | Scene index, with one row per scene |
| `poses/<channel>/<video_id>/<scene_id>.csv` | Timestamped camera positions, orientations, and pose status |
| `semantics/<channel>/<video_id>/<scene_id>.txt` | Timestamped English observations, inferences, and action descriptions |

Use `(channel, video_id, scene_id)` to join the index with the two annotation files. Scene IDs such as `scene_0000` are local to each video.

## Data fields

### Scene index

| Field | Meaning |
| --- | --- |
| `channel` | Source channel |
| `video_id` | YouTube video ID |
| `scene_id` | Scene identifier within the source video |
| `start_second`, `end_second` | Scene start and end times in the source video, in seconds |

### Camera poses

| Field | Meaning |
| --- | --- |
| `source_t` | Timestamp in the source video, in seconds |
| `source_frame` | Frame index in the source video |
| `status` | Pose status. Sample files contain `valid` rows with pose values and `bad` rows whose pose fields can be `NaN`. |
| `x`, `y`, `z` | Camera position components |
| `qx`, `qy`, `qz`, `qw` | Camera orientation quaternion, with the scalar component `qw` last |

The dataset files leave the position units, axis conventions, and coordinate relationships between scenes unspecified. Confirm these conventions before calculating physical distances or combining trajectories across scenes.

### Semantic annotations

Annotations are grouped by source-video timestamp in `[HH:MM:SS]` format. Each block contains an `Observation` describing what is visible, a `Latent Thought` expressing an inferred situation or intent in the first person, and an `Action` describing an action or plan.

Pose samples and semantic annotations can occur at different times. Join them by scene, then align them on the source-video timeline.

## Load a scene

Install `huggingface_hub` to download the public dataset. This example downloads the index and the two annotation files for its first scene.

```python
import csv
from pathlib import Path

from huggingface_hub import hf_hub_download

REPO_ID = "MonsterDie/SpatialSemanticDataset"


def download(filename):
    return Path(hf_hub_download(REPO_ID, filename, repo_type="dataset", token=False))


with download("metadata.csv").open(encoding="utf-8-sig", newline="") as file:
    scene = next(csv.DictReader(file))

key = "/".join(scene[field] for field in ("channel", "video_id", "scene_id"))

with download(f"poses/{key}.csv").open(encoding="utf-8-sig", newline="") as file:
    valid_poses = [row for row in csv.DictReader(file) if row["status"] == "valid"]

annotations = download(f"semantics/{key}.txt").read_text(encoding="utf-8-sig")

print(scene)
print(f"Valid poses: {len(valid_poses)}")
print(annotations.split("\n\n", 1)[0])
```

The dataset ships without predefined splits. When creating training and evaluation splits, group scenes by `(channel, video_id)` so that scenes from the same source video stay in the same split.

## License

The dataset card declares the MIT license. Source videos are subject to their own terms.