nn.ReLu is a class, not a function.
When you do x=nn.ReLu(x) you are instantiating the class nn.ReLu, not computing a relu. You can either replace nn.ReLu by it’s corresponding nn.functional.relu or to instantiate the activation in the init:
self.relu=nn.ReLu() and replace x = nn.ReLU(x) by ``x=self.relu(x)