Permalink
Find file
Fetching contributors…
Cannot retrieve contributors at this time
13 lines (7 sloc) 284 Bytes
from vectorSimilarities import VectorSimilarities
class BookSimilarities(VectorSimilarities):
def input(self, key, line):
user_id, item_id, rating = line.split(';')
yield item_id, (user_id, float(rating))
if __name__ == '__main__':
BookSimilarities.run()