dd2 dd2 - 1 year ago 190
Python Question

Tensorflow: method to save and restore TensorFlowEstimator()

How to save and load this object (


from tensorflow.contrib import learn
regressor = learn.TensorFlowEstimator()

I could not use tensorflow's default Saver() to save it.

How to do incremental learning with this model? I am confused about
parameter in its constructor. It says you can call fit again and again with new data. And at the same time it provides
. Please help me understand ?

Answer Source

According to this TF tutorial, the following should work:

for saving:


for restoring:

new_regressor = TensorFlowEstimator.restore('/tmp/tf_examples/my_model_2')
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download