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
OpenDAS
Torchaudio
Commits
1ebfb3de
Unverified
Commit
1ebfb3de
authored
Mar 15, 2021
by
Caroline Chen
Committed by
GitHub
Mar 15, 2021
Browse files
Fix functional_cpu_test test name generation (#1393)
parent
32cd700a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
7 deletions
+3
-7
test/torchaudio_unittest/functional/functional_cpu_test.py
test/torchaudio_unittest/functional/functional_cpu_test.py
+3
-7
No files found.
test/torchaudio_unittest/functional/functional_cpu_test.py
View file @
1ebfb3de
...
@@ -13,7 +13,6 @@ from torchaudio_unittest.common_utils import (
...
@@ -13,7 +13,6 @@ from torchaudio_unittest.common_utils import (
TorchaudioTestCase
,
TorchaudioTestCase
,
skipIfNoSox
,
skipIfNoSox
,
)
)
from
torchaudio_unittest.backend.sox_io.common
import
name_func
from
.functional_impl
import
Lfilter
,
Spectrogram
from
.functional_impl
import
Lfilter
,
Spectrogram
...
@@ -254,17 +253,14 @@ class TestApplyCodec(TorchaudioTestCase):
...
@@ -254,17 +253,14 @@ class TestApplyCodec(TorchaudioTestCase):
def
test_wave
(
self
):
def
test_wave
(
self
):
self
.
_smoke_test
(
"wav"
,
compression
=
None
,
check_num_frames
=
True
)
self
.
_smoke_test
(
"wav"
,
compression
=
None
,
check_num_frames
=
True
)
@
parameterized
.
expand
([(
96
,),
(
128
,),
(
160
,),
(
192
,),
(
224
,),
(
256
,),
(
320
,)],
@
parameterized
.
expand
([(
96
,),
(
128
,),
(
160
,),
(
192
,),
(
224
,),
(
256
,),
(
320
,)])
name_func
=
name_func
)
def
test_mp3
(
self
,
compression
):
def
test_mp3
(
self
,
compression
):
self
.
_smoke_test
(
"mp3"
,
compression
,
check_num_frames
=
False
)
self
.
_smoke_test
(
"mp3"
,
compression
,
check_num_frames
=
False
)
@
parameterized
.
expand
([(
0
,),
(
1
,),
(
2
,),
(
3
,),
(
4
,),
(
5
,),
(
6
,),
(
7
,),
(
8
,)],
@
parameterized
.
expand
([(
0
,),
(
1
,),
(
2
,),
(
3
,),
(
4
,),
(
5
,),
(
6
,),
(
7
,),
(
8
,)])
name_func
=
name_func
)
def
test_flac
(
self
,
compression
):
def
test_flac
(
self
,
compression
):
self
.
_smoke_test
(
"flac"
,
compression
,
check_num_frames
=
False
)
self
.
_smoke_test
(
"flac"
,
compression
,
check_num_frames
=
False
)
@
parameterized
.
expand
([(
-
1
,),
(
0
,),
(
1
,),
(
2
,),
(
3
,),
(
3.6
,),
(
5
,),
(
10
,)],
@
parameterized
.
expand
([(
-
1
,),
(
0
,),
(
1
,),
(
2
,),
(
3
,),
(
3.6
,),
(
5
,),
(
10
,)])
name_func
=
name_func
)
def
test_vorbis
(
self
,
compression
):
def
test_vorbis
(
self
,
compression
):
self
.
_smoke_test
(
"vorbis"
,
compression
,
check_num_frames
=
False
)
self
.
_smoke_test
(
"vorbis"
,
compression
,
check_num_frames
=
False
)
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