aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/contrib/learn/python/learn/estimators/dnn.py
diff options
context:
space:
mode:
Diffstat (limited to 'tensorflow/contrib/learn/python/learn/estimators/dnn.py')
-rw-r--r--tensorflow/contrib/learn/python/learn/estimators/dnn.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/tensorflow/contrib/learn/python/learn/estimators/dnn.py b/tensorflow/contrib/learn/python/learn/estimators/dnn.py
index bfe1cd0aed..f9ba6711e6 100644
--- a/tensorflow/contrib/learn/python/learn/estimators/dnn.py
+++ b/tensorflow/contrib/learn/python/learn/estimators/dnn.py
@@ -748,15 +748,16 @@ class _DNNEstimator(estimator.Estimator):
To create a _DNNEstimator for binary classification, where
estimator = _DNNEstimator(
feature_columns=[sparse_feature_a_emb, sparse_feature_b_emb],
- head=head=head_lib._multi_class__head(n_classes=2),
+ head=head_lib._multi_class__head(n_classes=2),
hidden_units=[1024, 512, 256])
If your label is keyed with "y" in your labels dict, and weights are keyed
with "w" in features dict, and you want to enable centered bias,
- head=head_lib._multi_class__head(n_classes=2,
- label_name="x"
- weight_column_name="w",
- enable_centered_bias=True)
+ head = head_lib._multi_class__head(
+ n_classes=2,
+ label_name="x",
+ weight_column_name="w",
+ enable_centered_bias=True)
estimator = _DNNEstimator(
feature_columns=[sparse_feature_a_emb, sparse_feature_b_emb],
head=head,