lmjohns3 / theanets

Neural network toolkit for Python
http://theanets.rtfd.org
MIT License
328 stars 74 forks source link

Looks like save_progress and save_every are not working in v0.6.2 #87

Closed ibeltagy closed 8 years ago

ibeltagy commented 8 years ago

In v0.5.3, I used to use: exp = theanets.Experiment(theanets.Classifier, layers= ... , save_progress=path, save_every=int) which loads a saved model (if exists), then saves the new trained model every couple of minutes.

In v0.6.2, I get "an unexpected keyword argument 'save_every' ". I can still pass the two arguments to the function: exp.train() which successfully saves the model every couple of minutes, but it does not load the saved model.

lmjohns3 commented 8 years ago

Yes, the kwargs API changed a bit in the v0.6.x releases -- I figured it wouldn't be too difficult to move the training-specific args to the train method call. To load the model automatically, pass the path to the Experiment constructor:

exp = theanets.Experiment(path)
exp.train(save_progress=path, save_every=5)
lmjohns3 commented 8 years ago

I'm going to close this issue, please reopen if you think it needs fixing.