rasbt / machine-learning-book

Code Repository for Machine Learning with PyTorch and Scikit-Learn
https://sebastianraschka.com/books/#machine-learning-with-pytorch-and-scikit-learn
MIT License
3.39k stars 1.24k forks source link

Page 365, missing negative sign in the calculation of partial derivative of activation unit with respect to z(out) #140

Open acmoudleysa opened 1 year ago

acmoudleysa commented 1 year ago

$$ \frac{\partial a_1^{(out)}}{\partial z_1^{(out)}} = \frac{\partial}{\partial z_1^{out}}\cdot \frac{1}{1+e^{z_1^{(out)}}} = ... = \left(\frac{1}{1+e^{z_1^{(out)}}}\right) \cdot \left(1-\frac{1}{1+e^{z_1^{(out)}}}\right)$$

In this equation, the exponents should have negative sign