Skip to content

Commit eb902c7

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent e8db47e commit eb902c7

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

pytorch_lightning/utilities/memory.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,10 @@
2020
RECURSIVE_DICT_WITH_TENSORS = Union[Dict[str, torch.Tensor], Dict[Any, Any]]
2121

2222

23-
def recursive_detach(in_dict: RECURSIVE_DICT_WITH_TENSORS,
24-
to_cpu: bool = False,) -> Dict[str, Union[Any, Dict[str, torch.Tensor], torch.Tensor]]:
23+
def recursive_detach(
24+
in_dict: RECURSIVE_DICT_WITH_TENSORS,
25+
to_cpu: bool = False,
26+
) -> Dict[str, Union[Any, Dict[str, torch.Tensor], torch.Tensor]]:
2527
"""Detach all tensors in `in_dict`.
2628
2729
May operate recursively if some of the values in `in_dict` are dictionaries

0 commit comments

Comments
 (0)