From 2790e17cdc6760d7aec9789e16de195ad3c48f9d Mon Sep 17 00:00:00 2001 From: Chuan Zhang Date: Sat, 11 Jul 2020 18:45:57 -0400 Subject: [PATCH 1/2] convert 1 wave file to on the fly generation --- test/test_sox_compatibility.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/test/test_sox_compatibility.py b/test/test_sox_compatibility.py index 23d58a3fb1..cafcca71fc 100644 --- a/test/test_sox_compatibility.py +++ b/test/test_sox_compatibility.py @@ -74,7 +74,10 @@ def test_lowpass(self): cutoff_freq = 3000 - noise_filepath = common_utils.get_asset_path('whitenoise.wav') + noise_waveform = common_utils.get_whitenoise(sample_rate=44100, duration=5) + noise_filepath = self.get_temp_path('whitenoise.wav') + common_utils.save_wav(noise_filepath, noise_waveform) + E = torchaudio.sox_effects.SoxEffectsChain() E.set_input_file(noise_filepath) E.append_effect_to_chain("lowpass", [cutoff_freq]) From 2f50f1ee10ae72e3359c3d47ff1289b9ea90237c Mon Sep 17 00:00:00 2001 From: Chuan Zhang Date: Sun, 12 Jul 2020 18:59:22 -0400 Subject: [PATCH 2/2] remove sox backend from TestCommonVoice --- test/test_datasets.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/test/test_datasets.py b/test/test_datasets.py index 3ac7fae8ac..a02c365dec 100644 --- a/test/test_datasets.py +++ b/test/test_datasets.py @@ -46,9 +46,7 @@ def test_cmuarctic(self): data[0] -@common_utils.skipIfNoSoxBackend class TestCommonVoice(common_utils.TorchaudioTestCase): - backend = 'sox' path = common_utils.get_asset_path() def test_commonvoice(self):