Skip to content

Commit 02464ba

Browse files
bushshrubpytorchmergebot
authored andcommitted
clean up doc
1 parent cdd9847 commit 02464ba

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

torch/utils/data/datapipes/utils/common.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,8 @@ def validate_input_col(fn: Callable, input_col: Optional[Union[int, tuple, list]
2525
"""
2626
Checks that function used in a callable datapipe works with the input column
2727
28-
This simply ensures that the number of
29-
positional arguments matches
30-
the size of the input column. The function must not contain any non-default
28+
This simply ensures that the number of positional arguments matches the size
29+
of the input column. The function must not contain any non-default
3130
keyword-only arguments.
3231
3332
Examples:
@@ -42,14 +41,13 @@ def validate_input_col(fn: Callable, input_col: Optional[Union[int, tuple, list]
4241
Notes:
4342
If the function contains variable positional (`inspect.VAR_POSITIONAL`) arguments,
4443
for example, f(a, *args), the validator will accept any size of input column
45-
greater than or equal to the number of positional or keyword arguments.
44+
greater than or equal to the number of positional arguments.
4645
(in this case, 1).
4746
4847
Args:
4948
fn: The function to check.
5049
input_col: The input column to check.
51-
Returns:
52-
None.
50+
5351
Raises:
5452
ValueError: If the function is not compatible with the input column.
5553
"""

0 commit comments

Comments
 (0)