diff --git a/src/lerobot/configs/dataset.py b/src/lerobot/configs/dataset.py index d5c6fa312..c40c0fae2 100644 --- a/src/lerobot/configs/dataset.py +++ b/src/lerobot/configs/dataset.py @@ -41,8 +41,8 @@ class DatasetRecordConfig: video: bool = True # Upload dataset to Hugging Face hub. push_to_hub: bool = True - # Upload on private repository on the Hugging Face hub. - private: bool = False + # If True, upload as private; if None, defer to the org default on the Hub (only affects orgs). + private: bool | None = None # Add tags to your dataset on the hub. tags: list[str] | None = None # Number of subprocesses handling the saving of frames as PNG. Set to 0 to use threads only; diff --git a/src/lerobot/datasets/lerobot_dataset.py b/src/lerobot/datasets/lerobot_dataset.py index 9734bcc74..d0dcf087d 100644 --- a/src/lerobot/datasets/lerobot_dataset.py +++ b/src/lerobot/datasets/lerobot_dataset.py @@ -524,7 +524,7 @@ class LeRobotDataset(torch.utils.data.Dataset): license: str | None = "apache-2.0", tag_version: bool = True, push_videos: bool = True, - private: bool = False, + private: bool | None = None, allow_patterns: list[str] | str | None = None, upload_large_folder: bool = False, **card_kwargs, @@ -543,7 +543,8 @@ class LeRobotDataset(torch.utils.data.Dataset): tag_version: If ``True``, create a Git tag for the current codebase version. push_videos: If ``False``, skip uploading the ``videos/`` directory. - private: If ``True``, create a private repository. + private: If ``True``, create a private repository. If ``None`` + (default), defer to the org default on the Hub (only affects orgs). allow_patterns: Glob pattern(s) restricting which files to upload. upload_large_folder: If ``True``, use ``upload_large_folder`` instead of ``upload_folder`` for very large datasets.