It may take some work to do online updates with an MatrixFactorizationModel because you need to update some rows of the user/item factors. You may be interested in spark-indexedrdd (http://spark-packages.org/package/amplab/spark-indexedrdd).
We support save/load in Scala/Java. We are going to add Python support for model import/export soon. As a hack, try the following in Python: model = ALS.train(...) model.call("save", sc._jsc.sc(), "/tmp/als") # save model to somewhere newModel = MatrixFactorizationModel(sc._jvm.org.apache.spark.mllib.recommendation.MatrixFactorizationModel.load(sc._jsc.sc(), "/tmp/als")) Best, Xiangrui On Thu, Feb 26, 2015 at 10:42 AM, anishm <anish.mashan...@gmail.com> wrote: > I am a beginner to the world of Machine Learning and the usage of Apache > Spark. > I have followed the tutorial at > https://databricks-training.s3.amazonaws.com/movie-recommendation-with-mllib.html#augmenting-matrix-factors > <https://databricks-training.s3.amazonaws.com/movie-recommendation-with-mllib.html#augmenting-matrix-factors> > , and was succesfully able to develop the application. Now, as it is > required that today's web application need to be powered by real time > recommendations. I would like my model to be ready for new data that keeps > coming on the server. > The site has quoted: > * > A better way to get the recommendations for you is training a matrix > factorization model first and then augmenting the model using your ratings.* > > How do I do that? I am using Python to develop my application. Also, please > tell me how do I persist the model to use it again, or an idea how do I > interface this with a web service. > > Thanking you, > Anish Mashankar > A Data Science Enthusiast > > > > -- > View this message in context: > http://apache-spark-user-list.1001560.n3.nabble.com/How-to-augment-data-to-existing-MatrixFactorizationModel-tp21831.html > Sent from the Apache Spark User List mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: user-unsubscr...@spark.apache.org > For additional commands, e-mail: user-h...@spark.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscr...@spark.apache.org For additional commands, e-mail: user-h...@spark.apache.org