Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(datasets) Clarify the split docs in FederatedDataset #3912

Merged
merged 3 commits into from
Sep 10, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions datasets/flwr_datasets/federated_dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,11 @@ def load_partition(
not need to provide this argument, but if `partitioners={"train": 10,
"test": 100}`, you need to set it to differentiate which partitioner should
be used.
The split names you can choose from vary from dataset to dataset. You need
to check the dataset on the `Hugging Face Hub`<https://huggingface.co/
datasets>_ to see which splits are available. You can resplit the dataset
by using the `preprocessor` parameter (to rename, merge, divide, etc. the
available splits).

Returns
-------
Expand Down Expand Up @@ -203,6 +208,11 @@ def load_split(self, split: str) -> Dataset:
----------
split : str
Split name of the downloaded dataset (e.g. "train", "test").
The split names you can choose from vary from dataset to dataset. You need
to check the dataset on the `Hugging Face Hub`<https://huggingface.co/
datasets>_ to see which splits are available. You can resplit the dataset
by using the `preprocessor` parameter (to rename, merge, divide, etc. the
available splits).

Returns
-------
Expand Down