File size: 4,438 Bytes
934487d
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
---

license: apache-2.0
authors:
- Kunalmod
task_categories:
- robotics
tags:
- tsfile
- timeseries
- tabular
modality:
- timeseries
- tabular
pretty_name: SO101 Block-to-Box TsFile
configs:
- config_name: default
  data_files:
  - split: train
    path: data/kunalmod_so101_groot.tsfile
size_categories:
- 10K<n<100K
---


# SO101 Block-to-Box TsFile

This dataset provides the numeric robot trajectories from
[`Kunalmod/so101_groot`](https://huggingface.co/datasets/Kunalmod/so101_groot) as one Apache TsFile table. The LeRobot
v2.1 SO101 demonstrations cover grasping a block and placing it in a box.

## Source Dataset

- Author, repository owner, and uploader: [Kunalmod](https://huggingface.co/Kunalmod) (`Kunalmod`)
- License: Apache-2.0
- Split: `train`
- Scale: 50 episodes, 47,507 frame rows, 1 task, and 50 source Parquet shards
- Sampling frequency: 30 fps
- Robot type: `so101`
- LeRobot codebase version: `v2.1`
- Source data layout: `data/chunk-{episode_chunk:03d}/episode_{episode_index:06d}.parquet`
- Paper and citation: the source card does not provide either one
- Task `0`: `Grasp a block and put it in the box.`

## Data Layout

- TsFile: `data/kunalmod_so101_groot.tsfile`
- Table: `kunalmod_so101_groot`
- Rows: 47,507
- Devices: 50, identified by the two TAG columns
- Time precision: milliseconds
- Per-episode Time range: 0 to 39,600 ms

All 50 episode shards are represented in the table. Filter by `episode_index`
and `task_index` to select an episode trajectory.

## Schema

| Column | TsFile type | Role | Meaning |
|---|---|---|---|
| `Time` | TIMESTAMP | TIME | `round(timestamp * 1000)` in milliseconds |
| `episode_index` | STRING | TAG | Source episode index stored by the TsFile device/tag mechanism |
| `task_index` | STRING | TAG | Source task index stored by the TsFile device/tag mechanism |
| `frame_index` | INT64 | FIELD | Frame position within the episode |
| `sample_index` | INT64 | FIELD | Source global `index` value |
| `action_0` ... `action_5` | FLOAT | FIELD | Six SO101 action components |
| `observation_state_0` ... `observation_state_5` | FLOAT | FIELD | Six SO101 joint-state components |

The action and state component order is `main_shoulder_pan`,
`main_shoulder_lift`, `main_elbow_flex`, `main_wrist_flex`, `main_wrist_roll`,
and `main_gripper`.

## Transform Details

- `Time` is derived from the source timestamp and restarts at zero for every
  episode. The source `timestamp` is omitted because it equals `Time / 1000`
  seconds.
- `index` is renamed to `sample_index`; `frame_index` is preserved.
- `action[6]` is flattened to `action_0` through `action_5`.
- `observation.state[6]` is flattened to `observation_state_0` through
  `observation_state_5`.
- Rows are ordered by `episode_index`, `task_index`, and `Time`.
- No source trajectory row, episode, task, action dimension, or state dimension
  is removed.

## Videos

The 100 source MP4 files remain in the original repository and are not
included here. Each camera has 50 files at 640x480 and 30 fps:

- [`observation.images.base`](https://huggingface.co/datasets/Kunalmod/so101_groot/tree/main/videos/chunk-000/observation.images.base)
- [`observation.images.wrist`](https://huggingface.co/datasets/Kunalmod/so101_groot/tree/main/videos/chunk-000/observation.images.wrist)

Their source pattern is
`videos/chunk-{episode_chunk:03d}/{video_key}/episode_{episode_index:06d}.mp4`.
Use `episode_index` and `frame_index` to align each numeric row with both video
streams.

## Usage

```python

from tsfile import ColumnCategory, TsFileReader



path = "data/kunalmod_so101_groot.tsfile"

reader = TsFileReader(path)

table_name = "kunalmod_so101_groot"

schema = reader.get_all_table_schemas()[table_name]

columns = [

    column.get_column_name()

    for column in schema.get_columns()

    if column.get_category() in (ColumnCategory.TAG, ColumnCategory.FIELD)

]



with reader.query_table(table_name, columns, batch_size=65536) as result:

    batch = result.read_arrow_batch()

    print(batch.to_pandas().head())

reader.close()

```

## Attribution

The demonstrations were published by [Kunalmod](https://huggingface.co/Kunalmod) under the
Apache-2.0 license and were created with
[LeRobot](https://github.com/huggingface/lerobot). Cite the original Hugging
Face dataset URL above when using the data.