machine-learning-using-k8s icon indicating copy to clipboard operation
machine-learning-using-k8s copied to clipboard

Update model version number for TensorFlow + Keras training

Open arun-gupta opened this issue 6 years ago • 0 comments

Training Fashion-MNIST model using TensorFlow and Keras as explained at

Running the training gives:

Test accuracy: 0.885599970818
Traceback (most recent call last):
  File "mnist.py", line 89, in <module>
    main()
  File "mnist.py", line 86, in main
    export_model(model, args.model_export_path)
  File "mnist.py", line 69, in export_model
    outputs={t.name:t for t in model.outputs})
  File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/util/deprecation.py", line 324, in new_func
    return func(*args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/saved_model/simple_save.py", line 83, in simple_save
    b = builder.SavedModelBuilder(export_dir)
  File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/saved_model/builder_impl.py", line 425, in __init__
    super(SavedModelBuilder, self).__init__(export_dir=export_dir)
  File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/saved_model/builder_impl.py", line 100, in __init__
    "directory: %s" % export_dir)
AssertionError: Export directory already exists. Please specify a different export directory: s3://eks-ml-example/mnist/export/1

This error message should not come. Instead the model should be persisted with a new version number.

@Jeffwan will look into this

arun-gupta avatar Apr 16 '19 18:04 arun-gupta