C# Class MyMediaLite.RatingPrediction.BiasedMatrixFactorization

Matrix factorization with explicit user and item bias, learning is performed by stochastic gradient descent

Per default optimizes for RMSE. Alternatively, you can set the Loss property to MAE or LogisticLoss. If set to log likelihood and with binary ratings, the recommender implements a simple version Menon and Elkan's LFL model, which predicts binary labels, has no advanced regularization, and uses no side information.

This recommender makes use of multi-core machines if requested. Just set MaxThreads to a large enough number (usually multiples of the number of available cores). The parallelization is based on ideas presented in the paper by Gemulla et al.

Literature: Ruslan Salakhutdinov, Andriy Mnih: Probabilistic Matrix Factorization. NIPS 2007. http://www.mit.edu/~rsalakhu/papers/nips07_pmf.pdf Steffen Rendle, Lars Schmidt-Thieme: Online-Updating Regularized Kernel Matrix Factorization Models for Large-Scale Recommender Systems. RecSys 2008. http://www.ismll.uni-hildesheim.de/pub/pdfs/Rendle2008-Online_Updating_Regularized_Kernel_Matrix_Factorization_Models.pdf Aditya Krishna Menon, Charles Elkan: A log-linear model with latent features for dyadic prediction. ICDM 2010. http://cseweb.ucsd.edu/~akmenon/LFL-ICDM10.pdf Rainer Gemulla, Peter J. Haas, Erik Nijkamp, Yannis Sismanis: Large-Scale Matrix Factorization with Distributed Stochastic Gradient Descent. KDD 2011. http://www.mpi-inf.mpg.de/~rgemulla/publications/gemulla11dsgd.pdf

This recommender supports incremental updates. See the paper by Rendle and Schmidt-Thieme.

Inheritance: MatrixFactorization
Afficher le fichier Open project: zenogantner/MML-KDD Class Usage Examples

Protected Properties

Свойство Type Description
item_bias double[]
user_bias double[]

Méthodes publiques

Méthode Description
BiasedMatrixFactorization ( ) : System

Default constructor

ComputeLoss ( ) : double
Iterate ( ) : void
LoadModel ( string filename ) : void
Predict ( int user_id, int item_id ) : double
RemoveItem ( int item_id ) : void
RemoveUser ( int user_id ) : void
RetrainItem ( int item_id ) : void
RetrainUser ( int user_id ) : void
SaveModel ( string filename ) : void
ToString ( ) : string
Train ( ) : void

Méthodes protégées

Méthode Description
AddItem ( int item_id ) : void
AddUser ( int user_id ) : void
InitModel ( ) : void
Iterate ( IList rating_indices, bool update_user, bool update_item ) : void
IterateMAE ( IList rating_indices, bool update_user, bool update_item ) : void
IterateRMSE ( IList rating_indices, bool update_user, bool update_item ) : void

Method Details

AddItem() protected méthode

protected AddItem ( int item_id ) : void
item_id int
Résultat void

AddUser() protected méthode

protected AddUser ( int user_id ) : void
user_id int
Résultat void

BiasedMatrixFactorization() public méthode

Default constructor
public BiasedMatrixFactorization ( ) : System
Résultat System

ComputeLoss() public méthode

public ComputeLoss ( ) : double
Résultat double

InitModel() protected méthode

protected InitModel ( ) : void
Résultat void

Iterate() public méthode

public Iterate ( ) : void
Résultat void

Iterate() protected méthode

protected Iterate ( IList rating_indices, bool update_user, bool update_item ) : void
rating_indices IList
update_user bool
update_item bool
Résultat void

IterateMAE() protected méthode

protected IterateMAE ( IList rating_indices, bool update_user, bool update_item ) : void
rating_indices IList
update_user bool
update_item bool
Résultat void

IterateRMSE() protected méthode

protected IterateRMSE ( IList rating_indices, bool update_user, bool update_item ) : void
rating_indices IList
update_user bool
update_item bool
Résultat void

LoadModel() public méthode

public LoadModel ( string filename ) : void
filename string
Résultat void

Predict() public méthode

public Predict ( int user_id, int item_id ) : double
user_id int
item_id int
Résultat double

RemoveItem() public méthode

public RemoveItem ( int item_id ) : void
item_id int
Résultat void

RemoveUser() public méthode

public RemoveUser ( int user_id ) : void
user_id int
Résultat void

RetrainItem() public méthode

public RetrainItem ( int item_id ) : void
item_id int
Résultat void

RetrainUser() public méthode

public RetrainUser ( int user_id ) : void
user_id int
Résultat void

SaveModel() public méthode

public SaveModel ( string filename ) : void
filename string
Résultat void

ToString() public méthode

public ToString ( ) : string
Résultat string

Train() public méthode

public Train ( ) : void
Résultat void

Property Details

item_bias protected_oe property

the item biases
protected double[] item_bias
Résultat double[]

user_bias protected_oe property

the user biases
protected double[] user_bias
Résultat double[]