Menu

#4 Movielens data import parameter swapped

open
5
2010-09-10
2010-09-10
No

[Thanks to tdpessem]
In the file MovieLensImporter.java , on line 96, you see this piece of code:
StringTokenizer t = new StringTokenizer(s, String.valueOf(divider));
int item = Integer.parseInt(t.nextToken());
int user = Integer.parseInt(t.nextToken());
int rating = Integer.parseInt(t.nextToken());

This file imports the movielens data set in the database. The itemId is read first, then the userId is read. However, the documentation of the movielens dataset state that the data is in this format:
user id | item id | rating | timestamp.

Is it possible that itemId and userId are swapped mistakenly in the file movielensimporter.java?

First inspection confirms a swap.

Discussion


Log in to post a comment.

MongoDB Logo MongoDB