Bläddra i källkod

dist.destroy_process_group() bug fix

5.0
Glenn Jocher 4 år sedan
förälder
incheckning
afe1df385b
1 ändrade filer med 1 tillägg och 1 borttagningar
  1. +1
    -1
      train.py

+ 1
- 1
train.py Visa fil

@@ -356,7 +356,7 @@ def train(hyp):
if not opt.evolve:
plot_results() # save as results.png
print('%g epochs completed in %.3f hours.\n' % (epoch - start_epoch + 1, (time.time() - t0) / 3600))
dist.destroy_process_group() if torch.cuda.device_count() > 1 else None
dist.destroy_process_group() if device.type != 'cpu' and torch.cuda.device_count() > 1 else None
torch.cuda.empty_cache()
return results


Laddar…
Avbryt
Spara