Created
March 19, 2017 13:50
-
-
Save mini-ninja-64/1ff54f628a806b270b71b9fc51d5e297 to your computer and use it in GitHub Desktop.
sigmoid functions
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
float activate(float x) | |
{ | |
return 1.0/(1.0+exp(-x)); | |
} | |
float activateDerivative(float x) | |
{ | |
return activate(x)*(1.0 - activate(x)); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment