Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LOCABAL梯度下降式子疑问 #138

Closed
flyxu opened this issue Mar 5, 2018 · 5 comments
Closed

LOCABAL梯度下降式子疑问 #138

flyxu opened this issue Mar 5, 2018 · 5 comments

Comments

@flyxu
Copy link

flyxu commented Mar 5, 2018

您好,我看到您写的LOCABAL算法了,我对您用的梯度下降公式有点疑问,您在哪儿找到的这个公式,我在原论文里没找到啊,然后我在其他论文里找到了部分,a synthetic approach for recommendation combining ratings social relations and reviews. 这个论文里使用了LOCABAL算法,他给出的迭代公式和您代码里写的还是有很大不同的。这里我还是有点疑惑的。

@Coder-Yu
Copy link
Owner

Coder-Yu commented Mar 9, 2018

好的,我会找时间看下,如果是我弄错了会修改的,谢谢反馈。

@flyxu
Copy link
Author

flyxu commented Mar 9, 2018

还有个bug,在qmath.py文件下pearson_sp这个函数第62行,return语句需要向前移动一格。

@Coder-Yu
Copy link
Owner

你好,我刚确认了一下,这个公式是我自己推导的。对比了一下nju的那篇文章,似乎是一致的?可能是我没有看仔细,你可以指出是哪个地方不一致吗?一般公式要是推导错误的话,运算时都是会溢出的。实测这个方法是可以收敛的。qmath的bug我已经修复了,谢谢。

@flyxu
Copy link
Author

flyxu commented Mar 14, 2018

image
主要是对U的求导那块,我看文章里给的迭代公式是按照我上面的写法,对于Ui,公式中有两项,分别代表Ui信任的朋友和信任Ui的朋友,也就是一个代表Ui的入度,一个代表出度,我看您只是计算了UI的出度,然后分别对Ui和Uk更新,这儿不知道是不是等价,所以这儿有点疑问。

@Coder-Yu
Copy link
Owner

文章里给的是批梯度优化的目标函数,我用的是SGD的,是等价的。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants