Skip to content

Commit

Permalink
found bug in relu derivative
Browse files Browse the repository at this point in the history
  • Loading branch information
philwhln committed Dec 5, 2020
1 parent 1d363c7 commit a9552a9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion deriv8/activation_functions/relu.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ def relu(A: Tensor2D) -> Tensor2D:


def relu_derivative(Z: Tensor2D):
return [[1. if Zij > 0. else 1. for Zij in Zi] for Zi in Z]
return [[1. if Zij > 0. else 0. for Zij in Zi] for Zi in Z]

0 comments on commit a9552a9

Please sign in to comment.