Update executor.py
This commit is contained in:
parent
7ba75f6fe1
commit
24a0de00b8
@ -51,8 +51,7 @@ class Executor:
|
|||||||
if num_utts == 0:
|
if num_utts == 0:
|
||||||
continue
|
continue
|
||||||
logits = model(feats)
|
logits = model(feats)
|
||||||
loss, acc = criterion(logits, target, feats_lengths,
|
loss, acc = criterion(logits, target, feats_lengths, min_duration)
|
||||||
min_duration)
|
|
||||||
loss.backward()
|
loss.backward()
|
||||||
grad_norm = clip_grad_norm_(model.parameters(), clip)
|
grad_norm = clip_grad_norm_(model.parameters(), clip)
|
||||||
if torch.isfinite(grad_norm):
|
if torch.isfinite(grad_norm):
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user