Re: Can user id and item id be negative integers?

2014-08-09 Thread Tevfik Aytekin
AbstractIDMigrator is for being able to use String IDs (it converts Strings to Longs.) IDs are stored in Long types, so there should not be any problems with negative IDs, but in practice I have not work with negative IDs before. Tevfik On Wed, Aug 6, 2014 at 3:51 AM, Peng Zhang

Can user id and item id be negative integers?

2014-08-05 Thread Peng Zhang
Hi, Is it OK that we use negative ids? I have the impression that user id and item id should be natural integers like 0, 1, 2, because they are used as column number and row numbers. But today I am trying to use negative user id and item id, and they are working well with the item recommender

Re: Can user id and item id be negative integers?

2014-08-05 Thread Ted Dunning
On Tue, Aug 5, 2014 at 3:21 AM, Peng Zhang pzhang.x...@gmail.com wrote: But today I am trying to use negative user id and item id, and they are working well with the item recommender and dvd recommender. Which programs are you using?

Re: Can user id and item id be negative integers?

2014-08-05 Thread Pat Ferrel
Are they ALL negative? Maybe only the non-negatives are working or there are some conditions where negatives work. I certainly wouldn’t count on it because I’ll bet it isn’t working as it should. On Aug 5, 2014, at 4:03 PM, Ted Dunning ted.dunn...@gmail.com wrote: On Tue, Aug 5, 2014 at 3:21

Re: Can user id and item id be negative integers?

2014-08-05 Thread Peng Zhang
Hi, Does this support the possibility that user/item id can be negative? I am reading through the source code of org.apache.mahout.cf.taste.impl.model.AbstractIDMigrator. The hash() function is trying to convert a string id to a long id like this. It’s quite possible that the long id returned