tebesu / CollaborativeMemoryNetwork

Collaborative Memory Network for Recommendation Systems, SIGIR 2018
182 stars 55 forks source link

A problem about the paper's equation 5 #1

Closed SunYatong closed 6 years ago

SunYatong commented 6 years ago

Hello, @tebesu I have read your paper "Collaborative Memory Network for Recommendation Systems (SIGIR 2018)" and I am pretty interested in your work. But I am not sure about an implementation detail of the paper's equation 5: image where vector q^{h}_{u,i} is transformed by a matrix W^{h} before adding with other vectors (o^{h}_{u,i} and b^{h}). My problem is that the size of q^{h}_{u,i} is different given different i. Then how is it possible to determine the size of W^{h}?

As the code is not available yet, I open this issue here. Thank you very much in advance for checking my problem. Please let me know if I misunderstood the paper.

tebesu commented 6 years ago

Thank you for your interest and pointing this out. The paper is somewhat unclear for this portion.

The initial query for the memory is q_{ui} = m_u + e_i then the similarity is computed with respect to each vector in the neighborhood N(i) leading to q_{uiv} = m_u^T m_v + e_i^T m_v. Then the hop mapping from z_ui = \phi(W(m_u + e_i) + o + b). Let me know if you need further explanation.

I hope to get the code up soon.

SunYatong commented 6 years ago

I still didn't get it. I thought that the scalar q_{u,i,v} is the element of vector q_{u,i}. So the size of q_{u,i} equals to the number of v, i.e., N(i). Am I right?

tebesu commented 6 years ago

It should be that q_{ui} = m_u + e_i and we denote q_{uiv} to be the similarity between q_{ui} and the vth user in the neighborhood rather than v being each dimension of the vector q_{ui}. I think the paper explanation may be wrong.

SunYatong commented 6 years ago

OK I see. Thanks for your explanation. But I am still wondering how does q^{h}_{ui} get updated in multi-hops as illustrated in Figure 1(b)? Equation 5 and 6 give the updating rule of z^{h}_{ui} and q^{h}_{uiv} but I can't find the updating equation for q^{h}_{ui}.

tebesu commented 6 years ago

Sorry for the confusion, we will be fixing the notation/figure and updating the version on arxiv.

Equation 5 should be changed to \phi(W^h z_{ui}^{h-1} + o_{ui}^h + b^h) and we set the initial z_{ui}^0 = m_u + e_i.

Let me know if you require a further explanation.

SunYatong commented 6 years ago

Now I can understand the process of Figure 1(b).

Thanks a lot for your explanation!