GoogleCloudPlatform / tensorflow-without-a-phd

A crash course in six episodes for software developers who want to become machine learning practitioners.
Apache License 2.0
2.79k stars 911 forks source link

where is mlengine/trainer/task.py #31

Closed zkailinzhang closed 6 years ago

zkailinzhang commented 6 years ago

High-level Tensorflow (tf.layers) This version is is for models built using the tf.layers high-level API and wrapped in a tf.estimator.Estimator interface.

def model_fn(features, labels, mode):

... neural network layers ...

logits = tf.layers.dense(Y4, 200, use_bias=False)
bn = tf.layers.batch_normalization(logits,
    axis=1,
    center=True,
    scale=False,
    training=(mode == tf.estimator.ModeKeys.TRAIN))
Y5 = tf.nn.relu(bn)
# ...  more neural network layers ...

A complete sample is available in mlengine/trainer/task.py

mlengine/trainer/task.py theweb link is 404

zkailinzhang commented 6 years ago

https://github.com/GoogleCloudPlatform/tensorflow-without-a-phd/blob/master/tensorflow-mnist-tutorial/mlengine/trainer/task.py