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
cd583bda
Unverified
Commit
cd583bda
authored
Dec 20, 2021
by
Patrick von Platen
Committed by
GitHub
Dec 20, 2021
Browse files
[WavLM] Fix slow tests (#14845)
parent
281e1fba
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
tests/test_modeling_wavlm.py
tests/test_modeling_wavlm.py
+2
-2
No files found.
tests/test_modeling_wavlm.py
View file @
cd583bda
...
@@ -465,7 +465,7 @@ class WavLMModelIntegrationTest(unittest.TestCase):
...
@@ -465,7 +465,7 @@ class WavLMModelIntegrationTest(unittest.TestCase):
)
)
EXPECTED_HIDDEN_STATES_SLICE
=
torch
.
tensor
(
EXPECTED_HIDDEN_STATES_SLICE
=
torch
.
tensor
(
[[[
0.05
54
,
0.11
38
],
[
0.05
55
,
0.11
44
]],
[[
0.0
200
,
0.12
40
],
[
0.0059
,
0.060
7
]]]
[[[
0.05
77
,
0.11
61
],
[
0.05
79
,
0.11
65
]],
[[
0.0
199
,
0.12
37
],
[
0.0059
,
0.060
5
]]]
)
)
self
.
assertTrue
(
torch
.
allclose
(
hidden_states_slice
,
EXPECTED_HIDDEN_STATES_SLICE
,
rtol
=
1e-2
))
self
.
assertTrue
(
torch
.
allclose
(
hidden_states_slice
,
EXPECTED_HIDDEN_STATES_SLICE
,
rtol
=
1e-2
))
...
@@ -488,6 +488,6 @@ class WavLMModelIntegrationTest(unittest.TestCase):
...
@@ -488,6 +488,6 @@ class WavLMModelIntegrationTest(unittest.TestCase):
)
)
EXPECTED_HIDDEN_STATES_SLICE
=
torch
.
tensor
(
EXPECTED_HIDDEN_STATES_SLICE
=
torch
.
tensor
(
[[[
0.
213
2
,
0.
0486
],
[
0.
2119
,
0.0571
]],
[[
0.
13
86
,
0.1
837
],
[
0.
2455
,
0.0
614
]]]
[[[
0.
161
2
,
0.
4314
],
[
0.
1690
,
0.4344
]],
[[
0.
20
86
,
0.1
396
],
[
0.
3014
,
0.0
903
]]]
)
)
self
.
assertTrue
(
torch
.
allclose
(
hidden_states_slice
,
EXPECTED_HIDDEN_STATES_SLICE
,
rtol
=
1e-2
))
self
.
assertTrue
(
torch
.
allclose
(
hidden_states_slice
,
EXPECTED_HIDDEN_STATES_SLICE
,
rtol
=
1e-2
))
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