From ccba65151e09b4f14795f69b0abf8132ee04d037 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=BA=90=E6=96=87=E9=9B=A8?= <41315874+fumiama@users.noreply.github.com> Date: Sat, 24 Jun 2023 16:36:15 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E4=BB=A3=E7=A0=81=E7=BB=93?= =?UTF-8?q?=E6=9E=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- extract_feature_print.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/extract_feature_print.py b/extract_feature_print.py index 3ab2504..605d5dd 100644 --- a/extract_feature_print.py +++ b/extract_feature_print.py @@ -19,14 +19,11 @@ import soundfile as sf import numpy as np from fairseq import checkpoint_utils -device = torch.device("cuda" if torch.cuda.is_available() else "cpu") - +device = "cpu" if torch.cuda.is_available(): device = "cuda" elif torch.backends.mps.is_available(): device = "mps" -else: - device = "cpu" f = open("%s/extract_f0_feature.log" % exp_dir, "a+")