nfmcclure / tensorflow_cookbook

Code for Tensorflow Machine Learning Cookbook
https://www.packtpub.com/big-data-and-business-intelligence/tensorflow-machine-learning-cookbook-second-edition
MIT License
6.23k stars 2.41k forks source link

How to save KNN model and use it next testset? #140

Open ucasiggcas opened 6 years ago

ucasiggcas commented 6 years ago

Hello, Have tried to save the model use tf.train.Saver(),but end with failure ValueError: No variables to save Could U propose some way to solve it ? Thx

nfmcclure commented 6 years ago

Hi @ucasiggcas , Thanks for the feature request. You're correct that we should have a way to do saving/loading. I'll see what I can do in the next month or so. Currently I'm wrapped up in a rewrite for version 2 of the book, but will get to this soon.