How exp(-z) is working in a sigmoid function in neural networks while z is a matrix?
function g = sigmoid(z)
%SIGMOID Compute sigmoid function
%J = SIGMOID(z) computes the sigmoid of z.
g = 1.0 ./ (1.0 + exp(-z));
end
I'm going through the Andrew Ng Coursera course. I doubt that how exp(-z)
is computed directly while z
is a matrix?
Topic matrix logistic-regression neural-network octave
Category Data Science