flaviovdf / fpmc

Implementation of the Factorizing Personalized Markov Chains for Next-Basket Recommendation
BSD 3-Clause "New" or "Revised" License
67 stars 25 forks source link

About the input format #2

Open huHHhhuhu opened 8 years ago

huHHhhuhu commented 8 years ago

Hi Flavio,

Sorry for bothering you again for the following problem.

I’m wondering the input format. The “Readme" says the first column of “dt user from to” is the amount of time the user spent on “from” before going to “to”. So the unit of the amount of time is “second"?

i.e., if I have the following .tsv text document: --------timestamp----------userID--itemID-- 2009-04-08T01:53:56Z user01 item01 2009-04-08T01:57:47Z user01 item02

I should turn it into the format like: 231 user01 item01 item02

However, if the time interval exceeds a day, the value of the amount of time will be big.

flaviovdf commented 8 years ago

That's it. But this model does not consider time, it is necessary as input simply because that's how I had my files set-up for other models. You should look at:

https://github.com/flaviovdf/tribeflow or https://github.com/flaviovdf/prme

huHHhhuhu commented 8 years ago

Okay, Thanks a lot !

kjacks21 commented 5 years ago

I think #4 tried to ask this, but since this issue is still open I'll ask it here. I also looked at the samples in https://github.com/flaviovdf/tribeflow and it still wasn't clear to me. Let's say I want to replicate the input data from Figure 1 of the fpmc paper (see below).

image

Would it be like the following?

0 user01 [a, b, c] [b, c]
0 user01 [b, c] [a,b]
0 user02 [a] [a, c]
0 user03 [d] [c, e]
0 user03 [c, e] [e]

or

0 \t user01 \t  a b c \t b c
0 \t  user01 \t  b c \t a b
0 \t  user02 \t  a \t a c
0 \t  user03 \t d \t c e
0 \t  user03 \t c e \t e

In other words, it isn't clear how to represent the baskets. Thanks!

flaviovdf commented 5 years ago

Hi, as we detail in the paper we focused on baskets of fixed sizes. See pg 7 of the paper.

-- Flavio

On Thu, Nov 8, 2018 at 12:47 PM Kyle Jackson notifications@github.com wrote:

I think #4 https://github.com/flaviovdf/fpmc/issues/4 tried to ask this, but since this issue is still open I'll ask it here. I also looked at the samples in https://github.com/flaviovdf/tribeflow and it still wasn't clear to me. Let's say I want to replicate the input data from Figure 1 of the fpmc paper (see below).

[image: image] https://user-images.githubusercontent.com/11047068/48205782-cfe06c80-e33a-11e8-9d1c-fb6b2eb3923b.png

Would it be like the following?

0 user01 [a, b, c] [b, c] 0 user01 [b, c] [a,b] 0 user02 [a] [a, c] 0 user03 [d] [c, e] 0 user03 [c, e] [e]

In other words, it isn't clear how to represent the baskets. Thanks!

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/flaviovdf/fpmc/issues/2#issuecomment-437018536, or mute the thread https://github.com/notifications/unsubscribe-auth/AAf08M4tETQqfakbeFuX2YLgy3CRaSpgks5utEQVgaJpZM4H1Hey .