Spaces:
Running
Running
update
Browse files
examples/nx_clean_unet/step_2_train_model.py
CHANGED
@@ -250,8 +250,8 @@ def main():
|
|
250 |
|
251 |
clean_audio_list = torch.split(clean_audios, 1, dim=0)
|
252 |
enhanced_audio_list = torch.split(audio_g, 1, dim=0)
|
253 |
-
clean_audio_list = [t.squeeze().cpu().numpy() for t in clean_audio_list]
|
254 |
-
enhanced_audio_list = [t.squeeze().cpu().numpy() for t in enhanced_audio_list]
|
255 |
|
256 |
pesq_score_list: List[float] = run_batch_pesq(clean_audio_list, enhanced_audio_list, sample_rate=config.sample_rate, mode="nb")
|
257 |
|
|
|
250 |
|
251 |
clean_audio_list = torch.split(clean_audios, 1, dim=0)
|
252 |
enhanced_audio_list = torch.split(audio_g, 1, dim=0)
|
253 |
+
clean_audio_list = [t.squeeze().detach().cpu().numpy() for t in clean_audio_list]
|
254 |
+
enhanced_audio_list = [t.squeeze().detach().cpu().numpy() for t in enhanced_audio_list]
|
255 |
|
256 |
pesq_score_list: List[float] = run_batch_pesq(clean_audio_list, enhanced_audio_list, sample_rate=config.sample_rate, mode="nb")
|
257 |
|