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
d7ce106b
Commit
d7ce106b
authored
Feb 17, 2021
by
Hanhan Li
Committed by
A. Unique TensorFlower
Feb 17, 2021
Browse files
Minor comment updates in Transformer.
PiperOrigin-RevId: 357974971
parent
c013311e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
official/nlp/transformer/transformer.py
official/nlp/transformer/transformer.py
+2
-2
No files found.
official/nlp/transformer/transformer.py
View file @
d7ce106b
...
@@ -109,8 +109,8 @@ class Transformer(tf.keras.Model):
...
@@ -109,8 +109,8 @@ class Transformer(tf.keras.Model):
sequence. float tensor with shape [batch_size, target_length, vocab_size]
sequence. float tensor with shape [batch_size, target_length, vocab_size]
If target is none, then generate output sequence one token at a time.
If target is none, then generate output sequence one token at a time.
returns a dictionary {
returns a dictionary {
outputs: [batch_size, decoded
length]
outputs:
int tensor with shape
[batch_size, decoded
_
length]
scores: [batch_size
, float
]}
scores:
float tensor with shape
[batch_size]}
Even when float16 is used, the output tensor(s) are always float32.
Even when float16 is used, the output tensor(s) are always float32.
Raises:
Raises:
...
...
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