TypeError: 'tuple' object is not callable when using flatten layer

Remove the comma after nn.Flatten() and the error should be gone:

self.flatten      = nn.Flatten          (),  # <- note the comma
1 Like