From fd7bcb4eb75c7cc6a28bdceecadfd282857ff1b9 Mon Sep 17 00:00:00 2001 From: Brandon Carter Date: Mon, 25 Feb 2019 18:04:03 -0500 Subject: [PATCH] Fix reference in HParams docstring. In the tf.contrib.training.HParams.HParams class docstring, `tf.HParams` should be `tf.contrib.training.HParams`. (I don't think there currently exists a `tf.HParams` alias.) --- tensorflow/contrib/training/python/training/hparam.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/tensorflow/contrib/training/python/training/hparam.py b/tensorflow/contrib/training/python/training/hparam.py index 27f0d9b2e38..cb0a25f333b 100644 --- a/tensorflow/contrib/training/python/training/hparam.py +++ b/tensorflow/contrib/training/python/training/hparam.py @@ -353,8 +353,10 @@ class HParams(object): def my_program(): # Create a HParams object specifying the names and values of the # model hyperparameters: - hparams = tf.HParams(learning_rate=0.1, num_hidden_units=100, - activations=['relu', 'tanh']) + hparams = tf.contrib.training.HParams( + learning_rate=0.1, + num_hidden_units=100, + activations=['relu', 'tanh']) # Override hyperparameters values by parsing the command line hparams.parse(args.hparams) @@ -387,7 +389,7 @@ class HParams(object): # Define 3 hyperparameters: 'learning_rate' is a float parameter, # 'num_hidden_units' an integer parameter, and 'activation' a string # parameter. - hparams = tf.HParams( + hparams = tf.contrib.training.HParams( learning_rate=0.1, num_hidden_units=100, activation='relu') hparams.activation ==> 'relu'