Adding the padding to the conv layers is the right approach, but I’m unsure why you are slicing it in the forward:
    def forward(self, x):
        output = self.conv(x)
        if self.padding != 0:
            output = output[:, :, :-self.padding]
        return output

This would remove the “right hand side” of the padded output, so is this intended?
Also, nn.CrossEntropyLoss expects raw logits, so remove the nn.Softmax in your model and just pass the output of the last layer to the criterion.