In addition to it, I made a few observations.

You have a linear transformation self.linear1 = nn.Linear(12, 12) which simply takes a vector of dimension 12 and transforms it to the same dimension(i.e 12). You can avoid it and simply start from self.linear2 = nn.Linear(12, 8).
Since you are using nn.CrossEntropyLoss, you should not use softmax at the end of your network’s forward pass. nn.CrossEntropyLoss combines log_softmax and NLLLoss.