diff --git a/fluid/recommendation/ctr/network_conf.py b/fluid/recommendation/ctr/network_conf.py index 81ccf8fc3ce2cfe157409a5d72179fa4f6829eee..027dde276e5deb8db2f6eea2088ba5bcfbfdb79a 100644 --- a/fluid/recommendation/ctr/network_conf.py +++ b/fluid/recommendation/ctr/network_conf.py @@ -34,15 +34,11 @@ def ctr_dnn_model(embedding_size): label = fluid.layers.data(name='label', shape=[1], dtype='int64') - data_list = [dense_input] + sparse_input_ids - - + data_list = [dense_input] + sparse_input_ids + [label] cost = fluid.layers.cross_entropy(input=predict, label=label) avg_cost = fluid.layers.reduce_sum(cost) accuracy = fluid.layers.accuracy(input=predict, label=label) auc_var, batch_auc_var, auc_states = fluid.layers.auc(input=predict, label=label, num_thresholds=2**12, slide_steps=20) - data_list.append(label) - return avg_cost, data_list, auc_var, batch_auc_var diff --git a/fluid/recommendation/ctr/train.py b/fluid/recommendation/ctr/train.py index 038c30379c2ae600bbce433fe6fa1e36d93951f6..2030971ff2ecb91149874134ef69b006bf092c08 100644 --- a/fluid/recommendation/ctr/train.py +++ b/fluid/recommendation/ctr/train.py @@ -1,4 +1,5 @@ from __future__ import print_function + import argparse import os import time