attentional_factorization_machine
attentional_factorization_machine copied to clipboard
TensorFlow Implementation of Attentional Factorization Machine
数据处理代码
何老师,请问数据预处理部分是怎么实现的呢(train、validation、test三个文件怎么处理得到的),可以分享下代码吗? 邮箱:[email protected]
Hi, first at all thanks for sharing the code of your AFM implementation. We tried to replicate the results from the original paper. We executed the code exactly as was...
实数特征支持问题
hi 拜读了你的代码,似乎不支持实值特征,要求特征值 为0/1, 但fm 理论上是支持实值特征的, 请问这么设计的原因是什么?
您好博主: 如题,batch_norm_layer这个函数似乎源码中并没有用上。这个正常是放在哪块的呢?直接放在输入方直接做batch_norm的吗?
您好,请问一下: ### 最终得到attention_score表示的是交叉特征重要性,但是interaction_score表示的是什么呢?因为最终这两个score是相乘的,interaction_score还有可能是负数。 ### 比如下面截图的paper中,user-tag 和user-item中的interaction_score都是负的,那么最终是看attention_score大小来决定哪个交叉特征重要还是看attention_score*interaction_score谁大谁重要呢? 
self.attention_relu = tf.reduce_sum(tf.multiply(self.weights['attention_p'], tf.nn.relu(self.attention_mul + \ self.weights['attention_b'])), 2, keep_dims=True) # None * (M'*(M'-1)) * 1 self.attention_out = tf.nn.softmax(self.attention_relu) 我认为keep_dims应该为False. keep_dims如果为True, attention_relu的shape是(batch, m*(m-1)/2, 1) 接下来的softmax会在attention_relu的最后一个axis上做归一化, 这样是错误的.
I tried the quick example you gave: ------------------------------------------------------------------------------------------------------------- python FM.py --dataset ml-tag --epoch 20 --pretrain -1 --batch_size 4096 --hidden_factor 16 --lr 0.01 --keep 0.7 #params: 1537566 Init: train=1.0000, validation=1.0000 [52.3...
何老师,您好!我在使用这份代码的时候,对于FM可以复现出论文的结果;但对于AFM,目前在val上取得的最好RMSE为 0.4639,对应参数为:--epoch 100 --pretrain 1 --batch_size 4096 --hidden_factor [8,256] --keep [1.0,0.5] --lamda_attention 2.0 --lr 0.01 --batch_norm 0,而论文中得到的最好RMSE为0.433左右,请问我有哪些地方处理得有问题吗?
Sorry to bother you. I have send you an email but no reply yet. Is [email protected] a correct mail address?Thanks.