GoogleCloudPlatform / GoogleCloudPlatform/training-data-analyst

rl-on-gcp output directory is not being created when using --job-dir

Open
#540 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Jupyter Notebook
Stars
8.6k
Forks
6.1k
Avg merge
4h 44m
Merged PRs (30d)
2

Description

I am trying to follow the rl-on-gcp. I recreated the file structure on my local machine and proceed to train locally.

The *train model locally* commands in the tutorial are as follows:

> OUTPUT_DIR=rl_model
> JOBNAME=rl_train_$(date -u +%y%m%d_%H%M%S)
> REGION=us-central1
> PACKAGE_PATH=$PWD/rl_model_code/trainer
> export PYTHONPATH=${PYTHONPATH}:${PWD}/rl_model_code
> rm $OUTPUT_DIR
>
> gcloud ml-engine local train\
> --package-path=$PACKAGE_PATH\
> --module-name=trainer.task\
> --\
> --outdir=$OUTPUT_DIR

The actual instructions given on the tutorial seem to be outdated, for example `--outdir` should be `--job-dir`, and `gcloud ml-engine` should be `gcloud ai-platform`.

I run the following working commands which worked on another tutorial in the [official google docs][2]:

gcloud ai-platform local train --package-path trainer --module-name trainer.task --job-dir rl-model

#Result:

I am getting no errors however the output directory is not being created. Here is the console output:

/anaconda3/envs/.../.../python3.6/site-packages/h5py/__init__.py:36: FutureWarning: Conversion of the second argument of issubdtype from `float` to `np.floating` is deprecated. In future, it will be treated as `np.float64 == np.dtype(float).type`.
from ._conv import register_converters as _register_converters
Usage:
trainer.task --outdir=
[--eval]
[--n_games_per_update=]
[--n_hidden=]
[--discount_rate=]
[--learning_rate=]
Options:
-h, --help Show this screen and exit.
--eval If in eval, make a gif.
--outdir= Location to save model (or of saved model if eval).
--n_games_per_update= Number of games to play. [default: 10]
--n_hidden= # of hidden units [default: 10]
--discount_rate= Reward discount rate. [default: 0.95]
--learning_rate= Learning rate. [default: 0.01]

Any suggestions as to why the job directory is not being created? How can I resolve this? Thanks in advance.

[1]: https://github.com/GoogleCloudPlatform/training-data-analyst/tree/master/blogs/rl-on-gcp/cartpole_policy_gradients
[2]: https://cloud.google.com/ml-engine/docs/tensorflow/getting-started-keras?authuser=1

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.