This commit is contained in:
Glenn Jocher 2019-04-02 14:07:14 +02:00
parent e3781460f8
commit af61da5d41
1 changed files with 2 additions and 2 deletions

View File

@ -185,8 +185,8 @@ def train(
if best_loss == mloss['total']: if best_loss == mloss['total']:
os.system('cp ' + latest + ' ' + best) os.system('cp ' + latest + ' ' + best)
# Save backup weights every 5 epochs (optional) # Save backup weights every 10 epochs (optional)
if epoch > 0 and epoch % 5 == 0: if epoch > 0 and epoch % 10 == 0:
os.system('cp ' + latest + ' ' + weights + 'backup%g.pt' % epoch) os.system('cp ' + latest + ' ' + weights + 'backup%g.pt' % epoch)
# Calculate mAP # Calculate mAP