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
992a5bfa
Commit
992a5bfa
authored
Oct 16, 2020
by
Le Hou
Committed by
A. Unique TensorFlower
Oct 16, 2020
Browse files
Log transformer_scaffold configs.
PiperOrigin-RevId: 337540237
parent
83aad58f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
0 deletions
+2
-0
official/nlp/modeling/layers/transformer_scaffold.py
official/nlp/modeling/layers/transformer_scaffold.py
+2
-0
No files found.
official/nlp/modeling/layers/transformer_scaffold.py
View file @
992a5bfa
...
@@ -15,6 +15,7 @@
...
@@ -15,6 +15,7 @@
"""Keras-based transformer scaffold layer."""
"""Keras-based transformer scaffold layer."""
# pylint: disable=g-classes-have-attributes
# pylint: disable=g-classes-have-attributes
from
absl
import
logging
import
gin
import
gin
import
tensorflow
as
tf
import
tensorflow
as
tf
...
@@ -207,6 +208,7 @@ class TransformerScaffold(tf.keras.layers.Layer):
...
@@ -207,6 +208,7 @@ class TransformerScaffold(tf.keras.layers.Layer):
name
=
"output_layer_norm"
,
axis
=-
1
,
epsilon
=
1e-12
,
dtype
=
tf
.
float32
)
name
=
"output_layer_norm"
,
axis
=-
1
,
epsilon
=
1e-12
,
dtype
=
tf
.
float32
)
super
(
TransformerScaffold
,
self
).
build
(
input_shape
)
super
(
TransformerScaffold
,
self
).
build
(
input_shape
)
logging
.
info
(
"%s configs: %s"
,
self
.
__class__
.
__name__
,
self
.
get_config
())
def
get_config
(
self
):
def
get_config
(
self
):
config
=
{
config
=
{
...
...
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