@ModelData(value={"isRanking","wrmf","userFactors","itemFactors","trainMatrix"}) public class WRMFRecommender extends MatrixFactorizationRecommender
This implementation refers to the method proposed by Hu et al. at ICDM 2008.
Modifier and Type | Field and Description |
---|---|
protected SparseMatrix |
confindenceMinusIdentityMatrix
confindence Minus Identity Matrix{ui} = confidenceMatrix_{ui} - 1 =alpha * r_{ui} or log(1+10^alpha * r_{ui})
|
protected SparseMatrix |
preferenceMatrix
preferenceMatrix_{ui} = 1 if
r_{ui}>0 or preferenceMatrix_{ui} = 0 |
protected float |
weightCoefficient
confidence weight coefficient
|
initMean, initStd, itemFactors, learnRate, maxLearnRate, numFactors, numIterations, regItem, regUser, userFactors
conf, context, decay, earlyStop, globalMean, isBoldDriver, isRanking, itemMappingData, lastLoss, LOG, loss, maxRate, minRate, numItems, numRates, numUsers, ratingScale, recommendedList, testMatrix, topN, trainMatrix, userMappingData, validMatrix, verbose
Constructor and Description |
---|
WRMFRecommender() |
Modifier and Type | Method and Description |
---|---|
protected void |
setup()
setup
init member method
|
protected void |
trainModel()
train Model
|
predict, updateLRate
cleanup, evaluate, evaluateMap, getContext, getDataModel, getRecommendedList, isConverged, loadModel, predict, recommend, recommend, recommendRank, recommendRating, saveModel, setContext
protected float weightCoefficient
protected SparseMatrix confindenceMinusIdentityMatrix
protected SparseMatrix preferenceMatrix
r_{ui}>0 or preferenceMatrix_{ui} = 0
protected void setup() throws LibrecException
MatrixFactorizationRecommender
setup
in class MatrixFactorizationRecommender
LibrecException
- if error occurs during setting upprotected void trainModel() throws LibrecException
AbstractRecommender
trainModel
in class AbstractRecommender
LibrecException
- if error occurs during training modelCopyright © 2017. All Rights Reserved.