Skip to content
Discussion options

You must be logged in to vote

Hi, there are two ways you can do.

  1. Re-generate a new dataset.

basic steps:

old_dataset = LeRobotDataset(
    repo_id="",
    root="your_old_local_dir",
)

new_dataset = LeRobotDataset(
    repo_id="",
    root="your_new_local_dir",
)

current_episode_index = 0
for data_item in old_dataset:
    episode_index = data_item["episode_index"]

    if episode_index != current_episode_index:
        new_dataset.save_episode()
        current_episode_index = episode_index

    # your filter logic here, if failed, continue to next item

    new_dataset.add_frame(data_item)  # check key and dtype
  1. filter failed episodes on the fly (recommended)

basic steps:

dataset = LeRobotDataset(
    repo_id="",…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by milong26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #28 on May 13, 2025 14:25.