victoresque / pytorch-template

PyTorch deep learning projects made easy.
MIT License
4.7k stars 1.08k forks source link

Fix checkpoint resuming #58

Closed SunQpark closed 5 years ago

SunQpark commented 5 years ago

fix issues reported in #57

  1. reference before assignment error
  2. invalid sanity check

Fixing the first was much easier than I thought it to be. Moving line 93 up to the line 64 solved the problem.

For the second, the sanity check was there for fine-tuning condition, where a trained checkpoint is loaded and updated by new config.json file given by CLI argument. I noticed that new config file was simply being ignored, and made them work correctly.