dev.train #8
@ -331,6 +331,9 @@ while current_epoch < MAX_EPOCHS:
|
|||||||
|
|
||||||
if counter > 1:
|
if counter > 1:
|
||||||
patience += 1
|
patience += 1
|
||||||
|
|
||||||
|
if counter == 0:
|
||||||
|
patience = max(0, patience - 1)
|
||||||
|
|
||||||
|
|
||||||
txt_train_avg_loss = sum(text_batch_losses) / len(text_batch_losses)
|
txt_train_avg_loss = sum(text_batch_losses) / len(text_batch_losses)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user