Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ModelZoo
ResNet50_tensorflow
Commits
3a3c5b9d
Commit
3a3c5b9d
authored
May 01, 2017
by
Lukasz Kaiser
Committed by
GitHub
May 01, 2017
Browse files
Merge pull request #1427 from kepingwang/master
stack outputs instead of concat outputs
parents
428212c9
a9e99821
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
tutorials/rnn/ptb/ptb_word_lm.py
tutorials/rnn/ptb/ptb_word_lm.py
+1
-1
No files found.
tutorials/rnn/ptb/ptb_word_lm.py
View file @
3a3c5b9d
...
...
@@ -157,7 +157,7 @@ class PTBModel(object):
(
cell_output
,
state
)
=
cell
(
inputs
[:,
time_step
,
:],
state
)
outputs
.
append
(
cell_output
)
output
=
tf
.
reshape
(
tf
.
concat
(
axis
=
1
,
values
=
outputs
),
[
-
1
,
size
])
output
=
tf
.
reshape
(
tf
.
stack
(
axis
=
1
,
values
=
outputs
),
[
-
1
,
size
])
softmax_w
=
tf
.
get_variable
(
"softmax_w"
,
[
size
,
vocab_size
],
dtype
=
data_type
())
softmax_b
=
tf
.
get_variable
(
"softmax_b"
,
[
vocab_size
],
dtype
=
data_type
())
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment