title: Tensorflow TypeError: export_savedmodel() got an unexpected keyword argument 'graph_rewrite_specs'
body: <p>My tensorflow version is 1.8.</p>
  
  <p>In simple words, when I try to use tf.contrib.learn.KMeansClustering.export_savedmodel() method, I got this error.</p>
  
  <p>The <a href="https://www.tensorflow.org/api_docs/python/tf/contrib/learn/DNNLinearCombinedRegressor#export_savedmodel" rel="nofollow noreferrer">doc</a> shows that this method actually has an argument graph_rewrite_specs.</p>
  
  <p>My code is basically:</p>
  
  <pre><code>kmeans = tf.contrib.factorization.KMeansClustering(num_clusters=num_clusters,
                                        model_dir='model', 
                                        use_mini_batch=True,
                                        mini_batch_steps_per_iteration=1)
  
  # training code here...
  
  kmeans.export_savedmodel('saved', 
                           serving_input_receiver_fn, 
                           as_text=False,
                           graph_rewrite_specs=(GraphRewriteSpec((tag_constants.SERVING,tag_constants.TRAINING), ()),))
  </code></pre>
  
  <p>Is there any problem in my code?</p>