Skip to content

Commit 903820e

Browse files
authored
Merge pull request #58 from keineahnung2345/403-view
403_RNN_regressor.py missing line in comment
2 parents 40bcdb5 + 61d6dc6 commit 903820e

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

tutorial-contents/403_RNN_regressor.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,13 @@ def forward(self, x, h_state):
5555
# instead, for simplicity, you can replace above codes by follows
5656
# r_out = r_out.view(-1, 32)
5757
# outs = self.out(r_out)
58+
# outs = outs.view(-1, TIME_STEP, 1)
5859
# return outs, h_state
60+
61+
# or even simpler, since nn.Linear can accept inputs of any dimension
62+
# and returns outputs with same dimension except for the last
63+
# outs = self.out(r_out)
64+
# return outs
5965

6066
rnn = RNN()
6167
print(rnn)

0 commit comments

Comments
 (0)