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
be3d6c84
"git@developer.sourcefind.cn:chenpangpang/transformers.git" did not exist on "9f5fe635483c9c80d59c9523eef5cf19ed93174c"
Unverified
Commit
be3d6c84
authored
Dec 08, 2022
by
Matt
Committed by
GitHub
Dec 08, 2022
Browse files
Fix expected values for TF-ESM tests (#20680)
parent
c83703cb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
tests/models/esm/test_modeling_tf_esm.py
tests/models/esm/test_modeling_tf_esm.py
+7
-7
No files found.
tests/models/esm/test_modeling_tf_esm.py
View file @
be3d6c84
...
@@ -266,13 +266,13 @@ class TFEsmModelIntegrationTest(unittest.TestCase):
...
@@ -266,13 +266,13 @@ class TFEsmModelIntegrationTest(unittest.TestCase):
expected_slice
=
tf
.
constant
(
expected_slice
=
tf
.
constant
(
[
[
[
[
[
8.92
0963
,
-
10.5
91399
,
-
6.467
39
7
],
[
8.92
1518
,
-
10.5
89814
,
-
6.467
130
7
],
[
-
6.39
8084
6
,
-
13.913
25
7
,
-
1.12
9
19
38
],
[
-
6.39
6715
6
,
-
13.91
1
3
7
7
,
-
1.12
1
19
15
],
[
-
7.781
5733
,
-
13.951
929
,
-
3.74
38734
],
[
-
7.781
247
,
-
13.951
557
,
-
3.74
0592
],
]
]
]
]
)
)
self
.
assertTrue
(
numpy
.
allclose
(
output
[:,
:
3
,
:
3
].
numpy
(),
expected_slice
.
numpy
(),
atol
=
1e-
4
))
self
.
assertTrue
(
numpy
.
allclose
(
output
[:,
:
3
,
:
3
].
numpy
(),
expected_slice
.
numpy
(),
atol
=
1e-
2
))
@
slow
@
slow
def
test_inference_no_head
(
self
):
def
test_inference_no_head
(
self
):
...
@@ -284,9 +284,9 @@ class TFEsmModelIntegrationTest(unittest.TestCase):
...
@@ -284,9 +284,9 @@ class TFEsmModelIntegrationTest(unittest.TestCase):
expected_slice
=
tf
.
constant
(
expected_slice
=
tf
.
constant
(
[
[
[
[
[
0.144
22388
,
0.541
1936
,
0.324
9576
],
[
0.144
43092
,
0.541
25327
,
0.324
7739
],
[
0.3034
2406
,
0.005
49317
,
0.310
96306
],
[
0.3034
0484
,
0.005
26676
,
0.310
77722
],
[
0.32278
83
3
,
-
0.249
74644
,
0.341
35976
],
[
0.32278
04
3
,
-
0.249
87096
,
0.341
4628
],
]
]
]
]
)
)
...
...
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