Skip to content
Snippets Groups Projects
Commit 21a88c0b authored by Massimiliano Lupo Pasini's avatar Massimiliano Lupo Pasini
Browse files

LogSoftMax activation function used

parent 32c466a9
No related branches found
No related tags found
1 merge request!11Subsampler and qr
This commit is part of merge request !11. Comments created here will be created in the context of that merge request.
......@@ -146,7 +146,7 @@ class MLP(NeuralNetwork, ABC):
# Activation function for classification problem
if classification:
self.layers += [torch.nn.Softmax()]
self.layers += [torch.nn.LogSoftmax()]
# Multilayer perceptron
self.model = torch.nn.Sequential(*self.layers)
......@@ -224,7 +224,7 @@ class CNN2D(NeuralNetwork, ABC):
bias=self.use_bias)]
# Activation function for classification problem
self.layers += [torch.nn.Softmax()]
self.layers += [torch.nn.LogSoftmax()]
# Convolutional neural network
self.model = torch.nn.Sequential(*self.layers)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment