Created
January 13, 2019 16:02
-
-
Save lucifermorningstar1305/0ec013c0a40979bd6d2bd41affce9b1d to your computer and use it in GitHub Desktop.
This file contains hidden or 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
activation_function = lambda x: 1.0/(1.0 + np.exp(-x)) | |
input = np.random.randn(3,1) | |
W1 = np.random.randn(None, 1) | |
W2 = np.random.randn(None,1) | |
W3 = np.random.randn(None,1) | |
b1 = np.zeros(1) | |
b2 = np.zeros(1) | |
b3 = np.zeros(1) | |
hidden_1 = activation(np.dot(W1, input) + b1) | |
hidden_2 = activation(np.dot(W2, W1) + b2) | |
output = np.dot(W3, W2) + b3 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment