Return type of transforms.Compose() not recognized by linter

The return type of transforms.Compose() is not recognized as a tensor, even when transforms.ToTensor() is one of the transformations in it. Is there something wrong with my code/linter or is this a bug?

Specifications:

  • MacOS
  • torch version 2.0.0
  • torchvision version 0.15.1