3333local$ opentau-dataset-viz --repo-id lerobot/pusht --episode-index 0
3434```
3535
36+ - Visualize a local dataset directory without specifying `repo_id`:
37+ ```
38+ local$ opentau-dataset-viz --root data/lerobot/pusht --episode-index 0
39+ ```
40+
3641- Visualize using source MP4 assets when available (smaller .rrd files):
3742```
3843local$ opentau-dataset-viz --repo-id lerobot/pusht --episode-index 0 --camera-log-mode asset_video
@@ -443,8 +448,11 @@ def parse_args() -> dict:
443448 parser .add_argument (
444449 "--repo-id" ,
445450 type = str ,
446- required = True ,
447- help = "Name of hugging face repository containing a LeRobotDataset dataset (e.g. `lerobot/pusht`)." ,
451+ default = None ,
452+ help = (
453+ "Name of hugging face repository containing a LeRobotDataset dataset "
454+ "(e.g. `lerobot/pusht`). Optional when `--root` points to a local dataset directory."
455+ ),
448456 )
449457 parser .add_argument (
450458 "--episode-index" ,
@@ -555,6 +563,8 @@ def parse_args() -> dict:
555563 )
556564
557565 args = parser .parse_args ()
566+ if args .repo_id is None and args .root is None :
567+ parser .error ("Either `--repo-id` or `--root` must be provided." )
558568 return vars (args )
559569
560570
@@ -572,6 +582,12 @@ def main():
572582 if not PERMIT_URDF :
573583 kwargs ["urdf" ] = None
574584
585+ if repo_id is None :
586+ assert root is not None # guarded in parse_args
587+ # LeRobotDataset requires a repo_id; synthesize one for local-only visualization.
588+ local_name = Path (root ).expanduser ().resolve ().name or "dataset"
589+ repo_id = f"local/{ local_name } "
590+
575591 logging .info ("Loading dataset" )
576592 tolerance_schedule = [tolerance_s ]
577593 for candidate in [1e-3 , 3e-3 , 1e-2 ]:
0 commit comments