The only input which actually needs to be changed is the ratings matrix. So, in the Python version, I passed in the transpose
```python
us = sc.parallelize(range(U), slices) \
 	    .map(lambda x: update(x, usb.value[x, :], msb.value, Rb.value.T)) \
```

So indexing into R.T will be correct.

This can be done in the Scala version too - I'll take a look at modifying and checking the result is the same. The downside is of course possibly doubling up on memory for R (unless it's a view - Numpy creates a view into the matrix, not sure about COLT but I'm sure there's a way).

In any case, this approach to ALS is ultimately not scalable since the entire R is broadcast so you're still constrained by single node memory. The approach used in the papers and Mahout is to distribute R twice, once by user and once by item. So in Spark we'd have 2 RDDs of (id, (id, rating)), one grouped by userid, the other grouped by itemid, and cache those.