Created
August 22, 2012 20:29
-
-
Save marcelcaraciolo/3429070 to your computer and use it in GitHub Desktop.
moviesSimilarities
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from vectorSimilarities import VectorSimilarities | |
class MovieSimilarities(VectorSimilarities): | |
def input(self, key, line): | |
user_id, item_id, rating = line.split('|') | |
yield item_id, (user_id, float(rating)) | |
if __name__ == '__main__': | |
MovieSimilarities.run() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment