I am trying to build a recommender system using Spark's MLlib library. (using Scala) In order to be able to use the ALS train method , I need to build a rating matrix using the Rating() method (which is a part the package org.apache.spark.mllib.recommendation.Rating). The method requires an int be passed as the user id . However the dataset i am working with has 11 digit id's and hence throws an error when I try to pass it.
Does anyone know if there is some way around this where I can pass a long value into the Rating method ? Or someway to override this method ? Or someway to uniquely convert the 11 digit number to 10 or 9 digits while keeping it an int?
Any help will be greatly appreciated. Thanks