Could you post the stack trace as I’m not sure if this type of error is thrown in the plt.imshow() line of code.
Usually this error is raised, if you try to call a tensor like a function:
x = torch.randn(3, 24, 24)
x()
> TypeError: 'Tensor' object is not callable