spark-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aslan Bekirov <aslanbeki...@gmail.com>
Subject Re: Persisting MatrixFactorizationModel
Date Wed, 04 Dec 2013 17:54:19 GMT
I thought to convert model to RDD and save to HDFS, and then load it.

I will try your method. Thanks a lot.



On Wed, Dec 4, 2013 at 7:41 PM, Evan R. Sparks <evan.sparks@gmail.com>wrote:

> The model is serializable - so you should be able to write it out to disk
> and load it up in another program.
>
> See, e.g. - https://gist.github.com/ramn/5566596 (Note, I haven't tested
> this particular example, but it looks alright).
>
> Spark makes use of this type of scala (and kryo, etc.) serialization
> internally, so you can check the Spark codebase for more examples.
>
>
> On Wed, Dec 4, 2013 at 9:34 AM, Aslan Bekirov <aslanbekirov@gmail.com>wrote:
>
>> Hi All,
>>
>> I am creating a model by calling train method of ALS.
>>
>> val model = ALS.train(ratings.....)
>>
>> I need to persist this model.  Use it from different clients, enable
>> clients to make predictions using this model. In other words, persist and
>> reload this model.
>>
>> Any suggestions, please?
>>
>> BR,
>> Aslan
>>
>
>

Mime
View raw message