79168420

Date: 2024-11-07 23:58:23
Score: 0.5
Natty:
Report link
function cikti = sigmoidDerivative(x)
cikti = sigmoid(x) .* (1 - sigmoid(x));

this code part have to be changed to

function cikti = sigmoidDerivative(x)
cikti = x .* (1 - x);

because in the jacobian function, sigmodiDerivative() funtion is called with parameter that already calculated with sigmoid() function

[~ , jA1] = forward_pass(jinput_vals(i),W1,b1,W2,b2);
    derivW1 = -1 * W2'.* sigmoidDerivative(jA1) *jinput_vals(i);  

jA1 is already return from sigmoid() function and so repeated unnecessary sudden increase and decrease of lamba problem solved.

Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: SeAk