From a4271c1acbb68a3fea633b852c3208e16f6c5088 Mon Sep 17 00:00:00 2001 From: Emir <52050284+emirthab@users.noreply.github.com> Date: Sun, 16 Jul 2023 07:31:44 +0300 Subject: [PATCH] Fix Mac Slicon Problems * Fix mp3, wav selection. * Fix float64 error on apple slicons. --- rvcgui.py | 2 +- vc_infer_pipeline.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/rvcgui.py b/rvcgui.py index 66803a312..8b5d12209 100644 --- a/rvcgui.py +++ b/rvcgui.py @@ -414,7 +414,7 @@ def on_button_click(): def browse_file(): filepath = filedialog.askopenfilename ( - filetypes=[("Audio Files", "*.wav;*.mp3")]) + filetypes=[("Audio Files", ["*.mp3","*.wav"])]) filepath = os.path.normpath(filepath) # Normalize file path input_audio_entry.delete(0, tk.END) input_audio_entry.insert(0, filepath) diff --git a/vc_infer_pipeline.py b/vc_infer_pipeline.py index c1dcf8d77..9dd3027eb 100644 --- a/vc_infer_pipeline.py +++ b/vc_infer_pipeline.py @@ -330,7 +330,7 @@ def pipeline( pitch = pitch[:p_len] pitchf = pitchf[:p_len] pitch = torch.tensor(pitch, device=self.device).unsqueeze(0).long() - pitchf = torch.tensor(pitchf, device=self.device).unsqueeze(0).float() + pitchf = torch.tensor(pitchf, device=self.device, dtype=torch.float32).unsqueeze(0).float() t2 = ttime() times[1] += t2 - t1 for t in opt_ts: