Skip to content

Commit

Permalink
Fix typo in examples/recurrent_neural_network.py
Browse files Browse the repository at this point in the history
  • Loading branch information
vuong-ts committed Dec 20, 2017
1 parent c5256ff commit 9e8a5ca
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion mlfromscratch/deep_learning/layers.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ def forward_pass(self, X, training=True):
for t in range(timesteps):
# Input to state_t is the current input and output of previous states
self.state_input[:, t] = X[:, t].dot(self.U.T) + self.states[:, t-1].dot(self.W.T)
self.states[:, t] = self.activation.function(self.state_input[:, t])
self.states[:, t] = self.activation(self.state_input[:, t])
self.outputs[:, t] = self.states[:, t].dot(self.V.T)

return self.outputs
Expand Down
2 changes: 1 addition & 1 deletion mlfromscratch/examples/recurrent_neural_network.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from mlfromscratch.deep_learning import NeuralNetwork
from mlfromscratch.utils import train_test_split, to_categorical, normalize, Plot
from mlfromscratch.utils import get_random_subsets, shuffle_data, accuracy_score
from mlfromscratch.deep_learning.optimizers import GradientDescent, Adam, RMSprop, Adagrad, Adadelta
from mlfromscratch.deep_learning.optimizers import StochasticGradientDescent, Adam, RMSprop, Adagrad, Adadelta
from mlfromscratch.deep_learning.loss_functions import CrossEntropy
from mlfromscratch.utils.misc import bar_widgets
from mlfromscratch.deep_learning.layers import RNN, Activation
Expand Down

0 comments on commit 9e8a5ca

Please sign in to comment.