Reputation: 539
I noticed the definition of Keras Dense layer says: Activation function to use. If you don't specify anything, no activation is applied (ie. "linear" activation: a(x) = x).
So if we have a code like:
model.add(Dense(10, activation = None))
Is it basically the same as:
nn.linear(128, 10)
?
Thank you so much!
Upvotes: 2
Views: 2400
Reputation: 740
Yes, it is the same. model.add (Dense(10, activation = None))
or nn.linear(128, 10)
is the same, because it is not activated in both, therefore if you don't specify anything, no activation is applied. It is so!!! :)
Upvotes: 2