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
c7647f11
Commit
c7647f11
authored
Sep 11, 2020
by
A. Unique TensorFlower
Browse files
Internal change
PiperOrigin-RevId: 331250678
parent
36d73bf6
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
7 deletions
+1
-7
official/nlp/configs/encoders.py
official/nlp/configs/encoders.py
+1
-7
No files found.
official/nlp/configs/encoders.py
View file @
c7647f11
...
...
@@ -79,8 +79,6 @@ class MobileBertEncoderConfig(hyperparams.Config):
MobileBERT paper. 'layer_norm' is used for the teacher model.
classifier_activation: if using the tanh activation for the final
representation of the [CLS] token in fine-tuning.
return_all_layers: if return all layer outputs.
return_attention_score: if return attention scores for each layer.
"""
word_vocab_size
:
int
=
30522
word_embed_size
:
int
=
128
...
...
@@ -99,8 +97,6 @@ class MobileBertEncoderConfig(hyperparams.Config):
num_feedforward_networks
:
int
=
1
normalization_type
:
str
=
"layer_norm"
classifier_activation
:
bool
=
True
return_all_layers
:
bool
=
False
return_attention_score
:
bool
=
False
@
dataclasses
.
dataclass
...
...
@@ -209,9 +205,7 @@ def build_encoder(
key_query_shared_bottleneck
=
encoder_cfg
.
key_query_shared_bottleneck
,
num_feedforward_networks
=
encoder_cfg
.
num_feedforward_networks
,
normalization_type
=
encoder_cfg
.
normalization_type
,
classifier_activation
=
encoder_cfg
.
classifier_activation
,
return_all_layers
=
encoder_cfg
.
return_all_layers
,
return_attention_score
=
encoder_cfg
.
return_attention_score
)
classifier_activation
=
encoder_cfg
.
classifier_activation
)
if
encoder_type
==
"albert"
:
return
encoder_cls
(
...
...
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