Why does the "ffm_predict" function return "1/(1+exp(-t))"?
zceng opened this issue · comments
Zhen Zeng commented
I'm confused about the "ffm_predict" function in the ffm.cpp :
ffm_float ffm_predict(ffm_node *begin, ffm_node *end, ffm_model &model) {
ffm_float r = 1;
if(model.normalization) {
r = 0;
for(ffm_node *N = begin; N != end; N++)
r += N->v*N->v;
r = 1/r;
}
ffm_float t = wTx(begin, end, r, model);
return 1/(1+exp(-t));
}
After reading the paper, "Field-aware Factorization Machines for CTR Prediction", I think the return value should be the variable t
, not be the value of 1/(1+exp(-t))
. Could you answer my doubt ?