You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- `function(batch: Union[Dict[List], List[Any]], indices: List[int]) -> Union[Dict, Any]` if `batched=True` and `with_indices=True`
1788
1802
If no function is provided, default to identity function: lambda x: x
1789
1803
with_indices (:obj:`bool`, defaults to `False`): Provide example indices to `function`. Note that in this case the signature of `function` should be `def function(example, idx): ...`.
1790
-
input_columns (`Optional[Union[str, List[str]]]`, defaults to `None`): The columns to be passed into `function` as
1804
+
input_columns (`Optional[List[str]]`, defaults to `None`): The columns to be passed into `function` as
1791
1805
positional arguments. If `None`, a dict mapping to all formatted columns is passed as one argument.
1792
1806
batched (:obj:`bool`, defaults to `False`): Provide batch of examples to `function`
1793
1807
batch_size (`Optional[int]`, defaults to `1000`): Number of examples per batch provided to `function` if `batched=True`
@@ -1816,10 +1830,6 @@ def _map_single(
1816
1830
disable_tqdm (:obj:`bool`, defaults to `False`): Whether to silence tqdm's output.
1817
1831
desc (`Optional[str]`, defaults to `None`): Meaningful description to be displayed alongside with the progress bar while mapping examples.
1818
1832
"""
1819
-
assert (
1820
-
notkeep_in_memoryorcache_file_nameisNone
1821
-
), "Please use either `keep_in_memory` or `cache_file_name` but not both."
1822
-
1823
1833
# Reduce logging to keep things readable in multiprocessing with tqdm
0 commit comments