Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.xiph.org/xiph/opus.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dnn/torch/osce/train_vocoder.py')
-rw-r--r--dnn/torch/osce/train_vocoder.py22
1 files changed, 12 insertions, 10 deletions
diff --git a/dnn/torch/osce/train_vocoder.py b/dnn/torch/osce/train_vocoder.py
index 3572e962..ce6ef48c 100644
--- a/dnn/torch/osce/train_vocoder.py
+++ b/dnn/torch/osce/train_vocoder.py
@@ -126,16 +126,6 @@ if has_git:
with open(os.path.join(args.output, setup_name), 'w') as f:
yaml.dump(setup, f)
-ref = None
-# prepare inference test if wanted
-inference_test = False
-if type(args.test_features) != type(None):
- test_features = load_lpcnet_features(args.test_features)
- features = test_features['features']
- periods = test_features['periods']
- inference_folder = os.path.join(args.output, 'inference_test')
- os.makedirs(inference_folder, exist_ok=True)
- inference_test = True
# training parameters
@@ -161,6 +151,18 @@ if 'validation_dataset' in setup:
else:
run_validation = False
+ref = None
+# prepare inference test if wanted
+inference_test = False
+if type(args.test_features) != type(None):
+ test_features = load_lpcnet_features(args.test_features, version=data.version)
+ features = test_features['features']
+ periods = test_features['periods']
+ inference_folder = os.path.join(args.output, 'inference_test')
+ os.makedirs(inference_folder, exist_ok=True)
+ inference_test = True
+
+
# create model
model = model_dict[model_name](*setup['model']['args'], **setup['model']['kwargs'])