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
On Tue, Aug 5, 2014 at 3:21 AM, Peng Zhang 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?
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 wrote:
On Tue, Aug 5, 2014 at 3:21 AM, Peng Zhang wrote:
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
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 wrote:
> Hi,
>
>