code:
infer_path = config.infer_result_path
model._train_program._fleet_opt["dump_fields"] = ["insid", "click", "pctr", model.predict.name]
model._train_program._fleet_opt["dump_fields_path"] = infer_path
模型上一个二分累ctr预估模型
"insid", "click", "pctr", model.predict.name分别是表示用户名,点击label,输入的得分数据和模型预测输出数据
但是dump到文件的数据却是这样
用户名,点击label,输入的得分数据是正确的,但是模型预测输出数据数据不对
麻烦看下是什么问题?
2条答案
按热度按时间cwxwcias1#
是否可以提供下组网呢
b1uwtaje2#
是否可以提供下组网呢
这个是组网,是一个三层MLP
import os
import math
import paddle.fluid as fluid
import numpy as np
from sklearn.metrics import precision_score, recall_score
class Model(object):
"""
Model for ES
"""
definit(self):
"""
init
"""
self._dense_feature_dim = 21
self._fc_layers_size = [20, 10] # change to es model mlp
self._dense_param_name = "DenseFeatFactors"
self._is_bn = False # set False
self._train_program = fluid.Program()
self._startup_program = fluid.Program()
self._feed_vars = []
self._fetch_vars = []