View full-text article in PMC J Mach Learn Res. Author manuscript; available in PMC: 2019 May 22. Published in final edited form as: J Mach Learn Res. 2015;16:3367–3402. Search in PMC Search in PubMed View in NLM Catalog Add to search Copyright and License information PMC Copyright notice Algorithm 3.1. Rank-Restricted Efficient Maximum-Margin Matrix Factorization: softImpute-ALS1.InitializeA=UDwhereUm×ris a randomly chosen matrix with orthonormal columns andD=Ir,ther×ridentity matrix, andB=VDwithV=0.Alternatively, any prior solutionA=UDandB=VDcould be used as a warm start.2.GivenA=UDandB=VD,approximately solveminimizeB˜12‖PΩ(X−AB˜T)‖FT+λ2‖B˜‖F2(20)to updateB.We achieve that with the following steps:(a) LetX*=(PΩ(X)−PΩ(ABT))+ABT,stored assparsepluslow-rank.(b) SolveminimizeB˜12‖X*−AB˜T‖F2+λ2‖B˜‖F2,(21)with solutionB˜T=(D2+λI)−1DUTX*=(D2+λI)−1DUT(PΩ(X)−PΩ(ABT))(22)+(D2+λI)−1D2BT.(23)(c) Use this solution forB˜and updateVandD:i.Compute the SVD decompositionB˜D=U˜D˜2V˜T;ii.V←U˜,andD←D˜.3.GivenB=VD,solve forA.By symmetry, this is equivalent to step2,withXTreplacingX,andBandAinterchanged.4.Repeat steps(2)−(3)until convergence.5.ComputeM=X*V,andthenit'sSVD:M=UDσRT.Then outputU,V←VRandDσ,λ=diag[(σ1−λ)+,…,(σr−λ)+].