Hi,
On Wed, Jan 7, 2015 at 11:13 AM, Riginos Samaras
wrote:
> exactly thats what I'm looking for, my code is like this:
> //code
>
> val users_map = users_file.map{ s =>
>
> val parts = s.split(",")
>
> (parts(0).toInt, parts(1))
>
> }.distinct
>
> //code
>
>
> but i get the error:
>
> error: va
Hi,
On Wed, Jan 7, 2015 at 10:47 AM, Riginos Samaras
wrote:
> Yes something like this. Can you please give me an example to create a Map?
>
That depends heavily on the shape of your input file. What about something
like:
(for (line <- Source.fromFile(filename).getLines()) {
val items = line.
Hi,
it looks to me as if you need the whole user database on every node, so
maybe put the id->name information as a Map[Id, String] in a broadcast
variable and then do something like
recommendations.map(line => {
line.map(uid => usernames(uid))
})
or so?
Tobias