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
0079e98a
Commit
0079e98a
authored
Mar 15, 2017
by
Neal Wu
Committed by
GitHub
Mar 15, 2017
Browse files
Merge pull request #982 from arvind385801/hotfix/tranlate_tutorial
fixed a bug in sampled_loss(), made compatible for 0.12.0
parents
fe9a4f5a
0d8916f4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
tutorials/rnn/translate/seq2seq_model.py
tutorials/rnn/translate/seq2seq_model.py
+1
-1
No files found.
tutorials/rnn/translate/seq2seq_model.py
View file @
0079e98a
...
...
@@ -100,7 +100,7 @@ class Seq2SeqModel(object):
b
=
tf
.
get_variable
(
"proj_b"
,
[
self
.
target_vocab_size
],
dtype
=
dtype
)
output_projection
=
(
w
,
b
)
def
sampled_loss
(
labels
,
input
s
):
def
sampled_loss
(
inputs
,
label
s
):
labels
=
tf
.
reshape
(
labels
,
[
-
1
,
1
])
# We need to compute the sampled_softmax_loss using 32bit floats to
# avoid numerical instabilities.
...
...
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