dataset-workflows
Inspect, validate, create, load, stream, transform, visualize, and safely plan operations on LeRobot Dataset v3 repositories.
- License 许可
- Apache-2.0
- 最近更新
- 2026-09-03
- Stars
- ★ 351
- Forks
- 27
01 前言 Front Matter
- name
- dataset-workflows
- license
- Apache 2.0
- metadata
- { "disco-role": "operating" }
- description
- Inspect, validate, create, load, stream, transform, visualize, and safely plan operations on LeRobot Dataset v3 repositories.
- disable-model-invocation
- true
02 资源文件 8
- 参考文档references/api-reference.md7.1 KB
- 参考文档references/cli-reference.md4.7 KB
- 参考文档references/data-formats.md5.8 KB
- 参考文档references/troubleshooting.md7.5 KB
- 参考文档references/workflows.md7.4 KB
- 脚本scripts/dataset_operation_plan.py5.3 KB
- 脚本scripts/load_local_dataset.py6.6 KB
- 脚本scripts/transform_probe.py2.8 KB
03 SKILL.md 正文
Dataset workflows
Use this skill when the request mentions LeRobotDataset, LeRobotDatasetMetadata, a
LeRobot dataset root or repository, episodes, feature schemas, Parquet, MP4, image
transforms, statistics, streaming, porting, lerobot-edit-dataset,
lerobot-dataset-viz, lerobot-imgtransform-viz, or lerobot-convert-dcp.
This skill covers dataset storage and read/write planning. Route policy, training,
evaluation, and inference to policy-training-inference; route physical recording,
replay, cameras, robots, and teleoperators to robot-control-data-collection; route
Hub jobs, credentials, uploads, and other remote services to
extensions-and-services.
Boundary and safety
- Inspect before mutating. Dataset editing, conversion, re-encoding, stats writes, Hub access, downloads, uploads, and credential use are side effects. The default plan is local, bounded, and non-destructive.
- A local dataset is the exact directory containing
meta/,data/, and, for video features,videos/. Pass it explicitly asroot; preflightmeta/info.jsonand data shards before constructing a reader so a malformed local fixture cannot silently trigger a Hub download. - Never infer video readiness from a successful import. Check the declared video keys, referenced MP4 paths, decoder backend, and a bounded sample decode.
- Do not call
push_to_hub,modify_tasks, or an in-place edit without explicit user consent, an output/overwrite decision, and a rollback or backup plan. finalize()is mandatory after recording or conversion before reading or pushing. A missing Parquet footer can make an apparently complete dataset unreadable.
Inputs and outputs
Collect the LeRobot version, source kind (local fixture, local full dataset, Hub repo, or Storage Bucket), exact root/repo/revision, intended episodes, feature keys and shapes, FPS, image/video/depth status, decoder choice, transforms, statistics provenance, operation/output directory, overwrite intent, optional extras, and network/credential consent. Produce one of:
- a validated local load/stream plan and bounded sample report;
- a schema, episode, feature, statistics, or decoder diagnosis;
- a write/port/edit/convert plan with explicit output and validation gates; or
- a blocked report naming the missing evidence or optional dependency.
Load the detailed contracts from data-formats.md, api-reference.md, and workflows.md. Use cli-reference.md for commands and troubleshooting.md for recovery. The bundled read-only helpers are load_local_dataset.py, transform_probe.py, and dataset_operation_plan.py.
Fast decision workflow
- Classify the source. For a local fixture, require an existing root and do not
download. For a Hub dataset, decide whether metadata-only, cached full access,
or streaming is wanted. Storage Buckets require
repo_type="bucket"and streaming; non-streamingLeRobotDatasetcannot consume bucket data. - Preflight the layout. Confirm
meta/info.json,meta/stats.jsonwhen normalization is needed,meta/tasks.parquetwhen tasks exist,meta/episodes/*/*.parquet,data/*/*.parquet, and the MP4 files named by episode metadata for every video feature. Check that the declared v3 version, FPS, paths, and counts agree. - Validate schema and episodes. Compare Parquet columns to
info.features; verify numeric dtype/shape, image shape/order, task indices, contiguous episode ranges,dataset_from_index/dataset_to_index, andlength. Missing or malformed episode index is a metadata/data contract failure, not a reason to guess a repair. - Choose reader. Use
LeRobotDataset(repo_id, root=...)for random access andDataLoader; selectepisodes,episode_filter,delta_timestamps,image_transforms,return_uint8,video_backend, or depth output deliberately. UseStreamingLeRobotDatasetfor bounded Hub/bucket iteration, shuffling, and delta windows; it is anIterableDataset, not an indexable random-access set. - Probe a sample. Check returned keys, tensor shapes/dtypes/ranges, episode
boundaries, task text, and video decoding. A delta window is padded at an
episode edge and emits
<feature>_is_pad; offsets must be multiples of1/fpswithin tolerance. - Plan mutations. Name a distinct output root/repo, check it is absent or ask
for overwrite, estimate disk/time, and validate feature compatibility before
delete/split/merge/feature edits/conversion/re-encoding/stats recomputation.
modify_tasksis in-place in the current tool contract. Prefer dry-run helper output beforelerobot-edit-dataset. - Handoff. State exactly what passed, what was not tested (especially codecs, remote access, or optional viz), and which downstream skill owns the next step.
Creation and write gates
Create with LeRobotDataset.create(repo_id, fps, features, root=..., use_videos=...).
Feature entries need dtype and shape; numeric values must match NumPy dtype and
shape, image/video frames accept HWC or CHW arrays (or PIL), and every frame needs a
task. Recording code adds the standard timestamp, frame_index,
episode_index, index, and task_index features. Call add_frame repeatedly,
save_episode, then finalize; only after that call __getitem__, compute/verify
stats, or push. Use resume only with an explicit writable root.
Video storage uses MP4 per camera stream; image storage embeds image data in
Parquet. RGB encoding is PyAV-backed and needs the dataset/AV extra plus a codec
available in the FFmpeg/PyAV build. Depth video is a separate quantized 12-bit
stream with persisted depth parameters; decode to mm or m explicitly. An
image-only dataset is a valid CPU fallback, but it does not prove MP4 support.
Validation checklist
- Local preflight found all required metadata/data paths without network access.
info.codebase_versionis v3-compatible; feature keys, dtypes, shapes, FPS, and task/episode counts agree with Parquet.- Every requested episode is present; each frame range and referenced video range matches its declared length.
- Stats are present and shape-compatible with the features, or their absence is explicitly accepted by the downstream consumer.
- One bounded item or stream sample has expected tensors and task text; delta padding behavior is understood.
- Video backend and optional packages are proven separately from imports; codec failures are reported as unsupported/corrupt rather than worked around silently.
- Any edit has a distinct output or explicit overwrite/backup approval, and no Hub or long conversion was started during inspection.
04 同仓库更多 Skills
passnet-triton-opt
Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.
passnet-solve
END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.
passnet-skill
PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.
passnet-pattern-fusion
Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.
passnet-orchestrate
Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.
passnet-feedback
Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).