mirror of
https://github.com/wassname/TTS.git
synced 2026-09-06 16:30:13 +08:00
use grad_clip from config.json
This commit is contained in:
@@ -134,7 +134,7 @@ def train(model, criterion, criterion_st, optimizer, optimizer_st, scheduler,
|
||||
# backpass and check the grad norm for spec losses
|
||||
loss.backward(retain_graph=True)
|
||||
optimizer, current_lr = weight_decay(optimizer, c.wd)
|
||||
grad_norm, _ = check_update(model, 1.0)
|
||||
grad_norm, _ = check_update(model, c.grad_clip)
|
||||
optimizer.step()
|
||||
|
||||
# backpass and check the grad norm for stop loss
|
||||
|
||||
Reference in New Issue
Block a user