Fix up string formatting/concatenation to f-strings where feasible

This commit is contained in:
Aarni Koskela
2023-05-09 22:17:58 +03:00
parent 8fb16ceb28
commit 3ba6c3c83c
34 changed files with 121 additions and 101 deletions

View File

@@ -18,7 +18,7 @@ class TorchHijackForUnet:
if hasattr(torch, item):
return getattr(torch, item)
raise AttributeError("'{}' object has no attribute '{}'".format(type(self).__name__, item))
raise AttributeError(f"'{type(self).__name__}' object has no attribute '{item}'")
def cat(self, tensors, *args, **kwargs):
if len(tensors) == 2: