We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent becd6cd commit f795e92Copy full SHA for f795e92
torch/__init__.py
@@ -1108,7 +1108,7 @@ def is_tensor(obj: _Any, /) -> _TypeIs["torch.Tensor"]:
1108
r"""Returns True if `obj` is a PyTorch tensor.
1109
1110
Note that this function is simply doing ``isinstance(obj, Tensor)``.
1111
- Using that ``isinstance`` check is better for typechecking with mypy,
+ Using that ``isinstance`` check is better for type checking with mypy,
1112
and more explicit - so it's recommended to use that instead of
1113
``is_tensor``.
1114
0 commit comments