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

Fix spacing around : in parameters in docs #2601

Merged
merged 2 commits into from
Nov 15, 2023
Merged
Show file tree
Hide file tree
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
4 changes: 2 additions & 2 deletions datasets/flwr_datasets/partitioner/iid_partitioner.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class IidPartitioner(Partitioner):

Parameters
----------
num_partitions: int
num_partitions : int
The total number of partitions that the data will be divided into.
"""

Expand All @@ -44,7 +44,7 @@ def load_partition(self, node_id: int) -> datasets.Dataset:

Returns
-------
dataset_partition: Dataset
dataset_partition : Dataset
single dataset partition
"""
return self.dataset.shard(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def load_partition(self, node_id: int) -> datasets.Dataset:

Returns
-------
dataset_partition: Dataset
dataset_partition : Dataset
single dataset partition
"""
if len(self._node_id_to_natural_id) == 0:
Expand Down
6 changes: 3 additions & 3 deletions datasets/flwr_datasets/partitioner/partitioner.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,12 @@ def load_partition(self, node_id: int) -> Dataset:

Parameters
----------
node_id: int
node_id : int
the index that corresponds to the requested partition

Returns
-------
dataset_partition: Dataset
dataset_partition : Dataset
single dataset partition
"""

Expand All @@ -75,7 +75,7 @@ def is_dataset_assigned(self) -> bool:

Returns
-------
dataset_assigned: bool
dataset_assigned : bool
True if a dataset is assigned, otherwise False.
"""
return self._dataset is not None
2 changes: 1 addition & 1 deletion datasets/flwr_datasets/resplitter/merge_resplitter.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class MergeResplitter:

Parameters
----------
merge_config: Dict[str, Tuple[str, ...]]
merge_config : Dict[str, Tuple[str, ...]]
Dictionary with keys - the desired split names to values - tuples of the current
split names that will be merged together

Expand Down
4 changes: 2 additions & 2 deletions datasets/flwr_datasets/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,12 @@ def _instantiate_partitioners(

Parameters
----------
partitioners: Dict[str, Union[Partitioner, int]]
partitioners : Dict[str, Union[Partitioner, int]]
Dataset split to the Partitioner or a number of IID partitions.

Returns
-------
partitioners: Dict[str, Partitioner]
partitioners : Dict[str, Partitioner]
Partitioners specified as split to Partitioner object.
"""
instantiated_partitioners: Dict[str, Partitioner] = {}
Expand Down