user912830823
user912830823

Reputation: 1352

No output when running TensorFlow code on Cloud Machine Learning Engine

When I run the following in terminal:

$MODEL_DIR=output
gcloud ml-engine local train     --module-name trainer.task     --package-path trainer/     --job-dir $MODEL_DIR

It runs successfully but I don't get anything in the output folder. Although according to this I should see some files and checkpoints: https://cloud.google.com/ml-engine/docs/tensorflow/getting-started-training-prediction

In the code I've got this line to save my model:

save_path = saver.save(sess, "./my_mnist_model.ckpt")

That generates following files in the active directory: my_mnist_model.ckpt.index, my_mnist_model.ckpt.meta, my_mnist_model.ckpt.data-00000-of-00001

However they are not in output folder. And when I run it on the Cloud Machine Learning Engine I don't get anything in the specified output folder in my bucket either.

So the model is successfully trained but not saved anywhere.

What am I missing in my code / gcloud command?

Upvotes: 1

Views: 110

Answers (1)

user912830823
user912830823

Reputation: 1352

Just figured out myself that i need to handle --job-dir myself in the script. From the getting started manual i thought it is handled by gcloud command that runs training.

Upvotes: 1

Related Questions