From b78f4189a15de5a7e53fb6b3667ab2f6e96578f4 Mon Sep 17 00:00:00 2001 From: moto <855818+mthrok@users.noreply.github.com> Date: Sat, 3 Jun 2023 11:29:38 -0400 Subject: [PATCH] test spawn --- test/torchaudio_unittest/sox_effect/dataset_test.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test/torchaudio_unittest/sox_effect/dataset_test.py b/test/torchaudio_unittest/sox_effect/dataset_test.py index 4e99fad9cfc..cb90a645100 100644 --- a/test/torchaudio_unittest/sox_effect/dataset_test.py +++ b/test/torchaudio_unittest/sox_effect/dataset_test.py @@ -96,6 +96,7 @@ def test_apply_effects_file(self): batch_size=32, num_workers=4, worker_init_fn=init_random_seed, + multiprocessing_context=torch.multiprocessing.get_context('spawn'), ) for batch in loader: assert batch.shape == (32, 2, 2 * sample_rate) @@ -117,6 +118,7 @@ def test_apply_effects_tensor(self): batch_size=32, num_workers=4, worker_init_fn=init_random_seed, + multiprocessing_context=torch.multiprocessing.get_context('spawn'), ) for batch in loader: assert batch.shape == (32, 2, 2 * sample_rate)