| --- |
| tags: |
| - tsfile |
| - timeseries |
| - lerobot |
| - atari |
| - demon-attack |
| - pi0 |
| - validation |
| modality: timeseries |
| size_categories: |
| - 10K<n<100K |
| pretty_name: Demon Attack Pi0 Validation (TsFile) |
| configs: |
| - config_name: default |
| data_files: |
| - split: validation |
| path: data/demon_attack_pi0_validation.tsfile |
| --- |
| |
| # Demon Attack Pi0 Validation (TsFile) |
|
|
| This dataset contains the numeric time-series data from |
| [`talha1503/demon_attack_pi0_validation`](https://huggingface.co/datasets/talha1503/demon_attack_pi0_validation), |
| converted from its LeRobot v2.0 Atari layout to one Apache TsFile. The task asks |
| an agent playing Demon Attack from a single game image to choose one of `NOOP`, |
| `FIRE`, `RIGHT`, `LEFT`, `RIGHTFIRE`, or `LEFTFIRE`, avoid enemy fire, survive, |
| and shoot enemies to maximize score. |
|
|
| - **Modalities:** Time-series in this repository; RGB images in the original repository |
| - **Split:** validation |
| - **Scale:** 29 episodes and 51,257 frames/rows |
| - **Sampling rate:** 30 FPS |
| - **Source files:** 29 episode Parquet files |
| - **Converted files:** 1 TsFile |
| - **Source revision:** `1a423750d2957d33cd2ec4c4931465eb8ab845b6` |
| - **License:** not specified by the source repository |
|
|
| ## Data File |
|
|
| The complete converted numeric dataset is stored at |
| [`data/demon_attack_pi0_validation.tsfile`](data/demon_attack_pi0_validation.tsfile). |
| It contains the table `demon_attack_pi0_validation`. Each source frame maps to |
| one row, while episode and task identifiers form the TsFile TAG dimensions. |
|
|
| ## TsFile Schema |
|
|
| | Column | TsFile role | Type | Description | |
| |---|---|---|---| |
| | `Time` | TIME | INT64 timestamp (ms) | `round(timestamp * 1000)` within each episode | |
| | `episode_index` | TAG | STRING (source INT64) | Source episode index, `0` through `28` | |
| | `task_index` | TAG | STRING (source INT64) | Source task index; `0` for this dataset | |
| | `frame_index` | FIELD | INT64 | Frame index within the episode | |
| | `sample_index` | FIELD | INT64 | Source global sample `index` | |
| | `done` | FIELD | INT64 | Source boolean terminal flag encoded as `0` or `1` | |
| | `is_success` | FIELD | INT64 | Source boolean success flag encoded as `0` or `1` | |
| | `state_0` | FIELD | FLOAT | The one-dimensional source `state` vector | |
| | `actions_0` ... `actions_5` | FIELD | FLOAT | The six-dimensional source `actions` vector | |
|
|
| ## Conversion Notes |
|
|
| - Source `timestamp` is represented by the TsFile `Time` column in milliseconds |
| and is not duplicated as a FIELD. |
| - Source `index` is renamed to `sample_index`. |
| - `state` is flattened to `state_0` and `actions` is flattened to `actions_0` |
| through `actions_5`, using single-precision FLOAT fields. |
| - Source boolean columns `done` and `is_success` are stored as INT64 `0`/`1` |
| flags for reliable TsFile readback. |
| - `episode_index` and `task_index` are TAG columns, allowing all 29 episodes to |
| remain in one TsFile. |
| - Detailed source-to-TsFile mappings are recorded in |
| [`meta/info.json`](meta/info.json). |
|
|
| ## Images |
|
|
| The source `image` feature is a `160 x 160 x 3` RGB image embedded in each |
| episode Parquet file. It is intentionally omitted from this numeric TsFile |
| conversion rather than expanded into 76,800 scalar values per frame. The images |
| remain available in the |
| [`original dataset`](https://huggingface.co/datasets/talha1503/demon_attack_pi0_validation). |
| The preserved episode, frame, task, and sample indices maintain frame-level |
| alignment with the source rows. The source repository contains no MP4 files. |
|
|
| ## Reading the TsFile |
|
|
| ```python |
| from tsfile import TsFileReader |
| |
| reader = TsFileReader("data/demon_attack_pi0_validation.tsfile") |
| columns = [ |
| "episode_index", |
| "task_index", |
| "frame_index", |
| "sample_index", |
| "done", |
| "is_success", |
| "state_0", |
| "actions_0", |
| ] |
| |
| with reader.query_table( |
| "demon_attack_pi0_validation", columns, batch_size=65536 |
| ) as result: |
| first_batch = result.read_arrow_batch() |
| print(first_batch) |
| ``` |
|
|
| ## Source and Attribution |
|
|
| The source repository did not provide a dataset card, paper, citation, author |
| list, or license metadata. Its available LeRobot metadata, task description, |
| episode Parquet files, and embedded images are preserved at |
| [`talha1503/demon_attack_pi0_validation`](https://huggingface.co/datasets/talha1503/demon_attack_pi0_validation). |
|
|