Skip to content

Commit 31c4048

Browse files
small revisions to code examples
1 parent d945e7a commit 31c4048

File tree

3 files changed

+3
-1
lines changed

3 files changed

+3
-1
lines changed

ML/Pytorch/Basics/pytorch_rnn_gru_lstm.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,7 @@ def forward(self, x):
130130
# gradient descent update step/adam step
131131
optimizer.step()
132132

133+
133134
# Check accuracy on training & test to see how good our model
134135
def check_accuracy(loader, model):
135136
num_correct = 0

ML/Pytorch/Basics/pytorch_simple_CNN.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,7 @@ def forward(self, x):
9494
# gradient descent or adam step
9595
optimizer.step()
9696

97+
9798
# Check accuracy on training & test to see how good our model
9899
def check_accuracy(loader, model):
99100
num_correct = 0

ML/Pytorch/Basics/pytorch_simple_fullynet.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ def forward(self, x):
9595
optimizer.step()
9696

9797

98-
# Check accuracy on training & test to see how good our model
98+
# Check accuracy on training & test to see how good our model is
9999
def check_accuracy(loader, model):
100100
num_correct = 0
101101
num_samples = 0

0 commit comments

Comments
 (0)