File size: 8,552 Bytes
1bfae7e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9ad11f8
 
 
1bfae7e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9ad11f8
1bfae7e
9ad11f8
1bfae7e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9ad11f8
 
 
 
 
 
1bfae7e
9ad11f8
1bfae7e
63d6245
 
 
 
 
 
 
 
 
 
 
 
 
 
1bfae7e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9ad11f8
 
 
 
 
 
 
 
1bfae7e
 
9ad11f8
1bfae7e
 
 
 
 
 
 
 
 
 
9ad11f8
1bfae7e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9ad11f8
1bfae7e
 
 
 
 
 
9ad11f8
 
 
 
 
 
 
 
 
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
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
---
license: other
task_categories:
  - robotics
tags:
  - robotics
  - dexterous-manipulation
  - teleoperation
  - motion-capture
  - human-hand
  - imitation-learning
  - hdf5
size_categories:
  - 10GB
---

# CAP — Dexterous Manipulation Capture Dataset (Cups Ordering, Right Hand)

CAP is a **human hand motion capture + dexterous manipulation demonstration** dataset. It records an operator performing the **cups ordering (`cups_order`)** task with the **right hand**. Data is captured with a DexCap-style pipeline and ships both **compressed trajectory HDF5 files** and **raw multi-view camera frames**, ready for motion retargeting, imitation learning, and hand-pose analysis.

- Repo: `dex-robot/cap`
- Main file: `cap.zip` (10,697,737,890 bytes ≈ 9.96 GiB)
- Contents: 18,939 files + 24 directory entries
- SHA256: `f91c11ee1761822fa875d4783c1fd9388f6fa3f0fa3feeef6cd5c20775220c10`
- Capture date: 2026-07-07
- Task: cups ordering
- Hand: right

---

## 1. Overview

| Item | Value |
| --- | --- |
| Task | `cups_order` (ordering cups) |
| Hand | Right |
| Capture date | 2026-07-07 |
| Recordings | 5 (16:46:34 / 16:54:35 / 16:56:54 / 16:59:04 / 17:01:24) |
| Trajectory files | 5 × `.hdf5` (one per recording) |
| Camera views | 6 (left hand / right hand / head stereo / head global RGB / head global depth) |
| Image frames | 18,914 × `.png` + 5 × `.mp4` |
| Other assets | 3 × `.json`, 6 × `.txt`, 5 × `.npy`, 1 × `.raw` |
| Archive size | 10.7 GB (10,697,737,890 bytes) |

---

## 2. Directory Layout

```
cap/
├── hdf5/                                   # one compressed trajectory per recording
│   ├── cups_order_right_hand_20260707_164634/
│   │   └── cups_order_right_hand_20260707_164634.hdf5
│   ├── cups_order_right_hand_20260707_165435/
│   │   └── cups_order_right_hand_20260707_165435.hdf5
│   ├── cups_order_right_hand_20260707_165654/
│   │   └── cups_order_right_hand_20260707_165654.hdf5
│   ├── cups_order_right_hand_20260707_165904/
│   │   └── cups_order_right_hand_20260707_165904.hdf5
│   └── cups_order_right_hand_20260707_170124/
│       └── cups_order_right_hand_20260707_170124.hdf5
└── raw_data/                               # raw multimodal stream (images + video + calibration)
    └── cups_order_right_hand_20260707_164634/
        └── cups_order_right_hand_20260707_164634_extracted/
            └── observe/
                └── vision/
                    ├── left_hand_rgb/            # left wrist view (video + metadata)
                    ├── right_hand_rgb/           # right wrist view
                    ├── head_zed_left/            # head ZED left
                    ├── head_zed_right/           # head ZED right
                    ├── head_global_rgb/          # head global RGB
                    ├── head_global_depth/        # head global depth
                    └── *_frames/                 # extracted PNG sequences per view
```

---

## 3. Recording Sessions

| Session ID | Start time | HDF5 trajectory | Raw frames |
| --- | --- | --- | --- |
| `cups_order_right_hand_20260707_164634` | 16:46:34 | ✅ | ✅ |
| `cups_order_right_hand_20260707_165435` | 16:54:35 | ✅ | — |
| `cups_order_right_hand_20260707_165654` | 16:56:54 | ✅ | — |
| `cups_order_right_hand_20260707_165904` | 16:59:04 | ✅ | — |
| `cups_order_right_hand_20260707_170124` | 17:01:24 | ✅ | — |

> Note: the full multi-view raw frames (18,915 PNG + 5 MP4) are published with the **first session** `164634`; the other four recordings ship as compressed HDF5 trajectories.

---

## 4. Camera Views & Frame Counts

| View directory | PNG frames | Video |
| --- | --- | --- |
| `head_global_depth_frames` | 5,565 | ✅ |
| `right_hand_rgb_frames` | 3,089 | ✅ |
| `head_zed_right_frames` | 2,629 | ✅ |
| `left_hand_rgb_frames` | 2,563 | ✅ |
| `head_zed_left_frames` | 2,546 | ✅ |
| `head_global_rgb_frames` | 2,522 | ✅ |

Frames are named `frame_%06d.png`, but the indices are **not strictly contiguous** (frames were dropped during capture). Always use the sorted filename order; do not assume `i` and `i+1` are adjacent.

### Preview

![Six views overview](preview_overview.png)

![Six views synced GIF](preview_grid.gif)

| Preview file | Content |
| --- | --- |
| `preview_overview.png` | single-frame overview of all 6 views |
| `preview_grid.gif` | all 6 views in sync (24 frames) |
| `preview_right_hand_rgb.gif` | right wrist view |
| `preview_head_global_rgb.gif` | head global RGB |
| `preview_head_global_depth.gif` | head global depth |

---

## 5. Download

### 5.1 huggingface-cli (recommended, resumable)

```bash
pip install -U "huggingface_hub[cli]"
export HF_ENDPOINT=https://hf-mirror.com        # optional mirror for CN networks
huggingface-cli download dex-robot/cap cap.zip --repo-type dataset --local-dir ./cap_data
```

### 5.2 Python

```python
from huggingface_hub import hf_hub_download
p = hf_hub_download("dex-robot/cap", "cap.zip", repo_type="dataset")
print(p)
```

### 5.3 Direct URL

```
https://huggingface.co/datasets/dex-robot/cap/resolve/main/cap.zip
```

---

## 6. Extract & Verify

```bash
# 1) size
stat -c %s cap.zip        # expected: 10697737890

# 2) SHA256
sha256sum cap.zip
# f91c11ee1761822fa875d4783c1fd9388f6fa3f0fa3feeef6cd5c20775220c10

# 3) CRC check (all 18963 entries must report OK)
unzip -t cap.zip

# 4) extract -> cap/
unzip -q cap.zip

du -sh cap
```

Expected:

```
cap/
├── hdf5/      (5 .hdf5 files)
└── raw_data/  (18,934 files)
```

---

## 7. Usage

### 7.1 Read an HDF5 trajectory

```python
import h5py

path = "cap/hdf5/cups_order_right_hand_20260707_164634/cups_order_right_hand_20260707_164634.hdf5"
with h5py.File(path, "r") as f:
    def show(name, obj):
        if isinstance(obj, h5py.Dataset):
            print(f"D {name:50s} shape={obj.shape} dtype={obj.dtype}")
        else:
            print(f"G {name}")
    f.visititems(show)
```

### 7.2 Read image frames

```python
import cv2, glob

frames = sorted(glob.glob(
    "cap/raw_data/cups_order_right_hand_20260707_164634/"
    "cups_order_right_hand_20260707_164634_extracted/observe/vision/"
    "head_global_rgb_frames/frame_*.png"))
print("frames:", len(frames))
img = cv2.imread(frames[0])
print(img.shape)  # (H, W, 3)
```

---

## 8. Recommended Environment

```bash
pip install h5py opencv-python numpy
```

- Python ≥ 3.8
- ~15 GB free disk after extraction (raw PNG sequences are large)
- `head_global_depth` may be 16-bit PNG or accompanied by `.npy` / `.raw` raw depth

---

## 9. License & Citation

- License: see the repo `LICENSE`; contact the publisher if unspecified.

```bibtex
@misc{cap_dataset_2026,
  title  = {CAP: Cups Ordering Dexterous Manipulation Capture Dataset (Right Hand)},
  author = {dex-robot},
  year   = {2026},
  howpublished = {\url{https://huggingface.co/datasets/dex-robot/cap}}
}
```

---

## 10. FAQ

**Q: Download interrupted?**
`huggingface-cli download` resumes automatically — just re-run the same command. Add `--max-workers 1` for a more stable (slower) transfer.

**Q: `unzip` says "End-of-central-directory signature not found"?**
The download is incomplete / truncated. Check that the size is exactly **10,697,737,890 bytes** and the SHA256 matches; if not, re-download.

**Q: I only need trajectories, not the 10 GB of images?**
Currently only the full bundle is published. Open a Discussion if you need a split release.

**Q: How do I align depth with RGB?**
`*_frames` and the MP4 of the same view share frame indices (`frame_%06d`). Cross-view alignment: use the calibration JSON under `raw_data/.../observe/vision/`.

---

## 11. Known Limitations

1. **Frame indices are not contiguous.** Each view's `frame_%06d.png` has gaps (frames dropped during capture) — e.g. `right_hand_rgb_frames` holds 3,089 frames with a max index of 3,746. Use sorted filename order; never infer the next frame as `i+1`.
2. **Raw frames cover the first session only.** Of the 5 recordings, only `164634` ships full multi-view PNG / MP4; the other four provide HDF5 trajectories only.
3. **HDF5 internal layout may evolve across capture versions.** Group / dataset names can differ between recordings — inspect the structure with `visititems` before reading arrays.
4. The archive was recovered from an interrupted packing process and passes CRC verification for all 18,963 entries; one incomplete trailing PNG frame was dropped.