Vansh Chugh commited on
Commit
6d3be73
·
1 Parent(s): c5b3e92

fix: use soundfile.write instead of torchaudio.save to avoid torchcodec

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -172,7 +172,7 @@ def process_fn(
172
 
173
  with tempfile.NamedTemporaryFile(suffix=".wav", delete=False) as f:
174
  out_path = f.name
175
- torchaudio.save(out_path, audio_out, sample_rate=SAMPLE_RATE)
176
  return out_path
177
 
178
 
 
172
 
173
  with tempfile.NamedTemporaryFile(suffix=".wav", delete=False) as f:
174
  out_path = f.name
175
+ sf.write(out_path, audio_out.T.numpy(), samplerate=SAMPLE_RATE)
176
  return out_path
177
 
178