Commit 516450e6 authored by Anthony Larcher's avatar Anthony Larcher
Browse files

debug

parent 59c9be2b
......@@ -1249,6 +1249,7 @@ def xdebug(speaker_number,
return model, training_set, validation_set
def xtime(model, training_set, validation_set,
speaker_number,
batch_size,
num_thread,
):
......@@ -1267,6 +1268,23 @@ def xtime(model, training_set, validation_set,
"""
Set the training options
"""
patience = 10
epochs = 2
device = torch.device("cuda:0" if torch.cuda.is_available() else "cpu")
with open(model_yaml, 'r') as fh:
model_archi = yaml.load(fh, Loader=yaml.FullLoader)
epochs = model_archi["training"]["epochs"]
patience = model_archi["training"]["patience"]
opt = model_archi["training"]["opt"]
lr = model_archi["training"]["lr"]
loss = model_archi["training"]["loss"]
aam_margin = model_archi["training"]["aam_margin"]
aam_s = model_archi["training"]["aam_s"]
tmp_model_name = model_archi["training"]["tmp_model_name"]
best_model_name = model_archi["training"]["best_model_name"]
multi_gpu = model_archi["training"]["multi_gpu"]
clipping = model_archi["training"]["clipping"]
if opt == 'adam':
_optimizer = torch.optim.Adam
_options = {'lr': lr}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment