Unverified Commit f766d7ac authored by Nicolas Hug's avatar Nicolas Hug Committed by GitHub
Browse files

Ignore some mypy errors (#8404)

parent 81343069
...@@ -188,7 +188,7 @@ class Cityscapes(VisionDataset): ...@@ -188,7 +188,7 @@ class Cityscapes(VisionDataset):
if t == "polygon": if t == "polygon":
target = self._load_json(self.targets[index][i]) target = self._load_json(self.targets[index][i])
else: else:
target = Image.open(self.targets[index][i]) target = Image.open(self.targets[index][i]) # type: ignore[assignment]
targets.append(target) targets.append(target)
......
...@@ -99,7 +99,7 @@ def fromfile( ...@@ -99,7 +99,7 @@ def fromfile(
class ReadOnlyTensorBuffer: class ReadOnlyTensorBuffer:
def __init__(self, tensor: torch.Tensor) -> None: def __init__(self, tensor: torch.Tensor) -> None:
self._memory = memoryview(tensor.numpy()) self._memory = memoryview(tensor.numpy()) # type: ignore[arg-type]
self._cursor: int = 0 self._cursor: int = 0
def tell(self) -> int: def tell(self) -> int:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment