Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
  • Loading branch information
jafermarq authored Mar 13, 2024
1 parent b9392aa commit 61efc4f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions datasets/flwr_datasets/federated_dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,9 +242,9 @@ def concatenate_divisions(
"""
if self._partition_division is None:
raise ValueError(
"The division concatenation is possible only if the partition_division "
"The division concatenation is possible only if the `partition_division` "
"is specified. To access all of the undivided partitions use "
"load_split."
"`load_split`."
)
if split is None:
self._check_if_no_split_keyword_possible()
Expand All @@ -257,7 +257,7 @@ def concatenate_divisions(
if not isinstance(division_id, int):
raise TypeError(
"The division_id needs to be an int in case of "
"partition_division specification as List."
"`partition_division` specification as List."
)
division = partition[division_id]
elif isinstance(partition, DatasetDict):
Expand All @@ -274,7 +274,7 @@ def concatenate_divisions(
if zero_len_divisions == self._partitioners[split].num_partitions:
raise ValueError(
"The concatenated dataset is of length 0. Please change the "
"partition_division parameter to change this behavior."
"`partition_division` parameter to change this behavior."
)
if zero_len_divisions != 0:
warnings.warn(f"{zero_len_divisions} division(s) have length zero.")
Expand Down

0 comments on commit 61efc4f

Please sign in to comment.