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
chenpangpang
transformers
Commits
4a666885
"fs/git@developer.sourcefind.cn:OpenDAS/ollama.git" did not exist on "cc6463ebca22e07b08db58eb335263d82844132f"
Commit
4a666885
authored
Nov 28, 2019
by
thomwolf
Committed by
Lysandre Debut
Nov 29, 2019
Browse files
reducing my level of enthousiasm
parent
adb5c79f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
transformers/modeling_tf_utils.py
transformers/modeling_tf_utils.py
+1
-1
No files found.
transformers/modeling_tf_utils.py
View file @
4a666885
...
@@ -494,7 +494,7 @@ class TFSequenceSummary(tf.keras.layers.Layer):
...
@@ -494,7 +494,7 @@ class TFSequenceSummary(tf.keras.layers.Layer):
def
shape_list
(
x
):
def
shape_list
(
x
):
"""Deal with dynamic shape in tensorflow cleanly."""
"""Deal with dynamic shape in tensorflow cleanly."""
static
=
x
.
shape
.
as_list
()
static
=
x
.
shape
.
as_list
()
dynamic
=
shape
_list
(
x
)
dynamic
=
tf
.
shape
(
x
)
return
[
dynamic
[
i
]
if
s
is
None
else
s
for
i
,
s
in
enumerate
(
static
)]
return
[
dynamic
[
i
]
if
s
is
None
else
s
for
i
,
s
in
enumerate
(
static
)]
def
get_initializer
(
initializer_range
=
0.02
):
def
get_initializer
(
initializer_range
=
0.02
):
...
...
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