Skip to content

Dataset split sometimes fails to split video frames due to float precision #2547

@mkiefel

Description

@mkiefel

System Info

Lerobot 0.4.3, Ubuntu 22.04, Python 3.12.8, numpy==2.2.6, torch==2.7.1, I did a clean `uv pip install -e .` on c55fbe1b.

Information

  • One of the scripts in the examples/ folder of LeRobot
  • My own task or dataset (give details below)

Reproduction

Running the following script creates an example lerobot dataset and splits it. However, the frames in the resulting videos will not have the corrent number of frames.

Accessing one of the split datasets' video frames will result in Invalid frame index=2153 for streamIndex=0; must be less than 2153.

test_lerobot_split.py

Expected behavior

The meta data and the videos should agree on the number of frames.

I will post a fix shortly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions