Research Article
Collaborative Filtering Recommendation Using Nonnegative Matrix Factorization in GPU-Accelerated Spark Platform
Algorithm 1
GPU-accelerated NMF on Spark.
| Input: Original matrix , low rank and iteration times | | Input: Context of Spark Environment | | Input: Number of executors and number of data partitions | | Input: Data collection of matrix elements and for matrices and | | Input: Data collection in the form of RDD and for matrices and | | Output: Matrices and after decomposition | | (1) generate initial , by random | | (2) | | (3) broadcast | | (4) for = 1: do | | (5) | | (6) //update | | (7) call | | (8) function mapH(data, result) | | (9) | | (10) | | (11) | | (12) | | (13) | | (14) | | (15) end function | | (16) | | (17) | | (18) //update | | (19) call | | (20) function mapW(data, result) | | (21) | | (22) | | (23) | | (24) | | (25) | | (26) | | (27) end function | | (28) | | (29) end for | | (30) |
|