public class ItemItemGlobalScorer extends AbstractGlobalItemScorer
Modifier and Type | Field and Description |
---|---|
protected ItemScoreAlgorithm |
algorithm |
protected ItemItemModel |
model |
protected NeighborhoodScorer |
scorer |
Constructor and Description |
---|
ItemItemGlobalScorer(ItemItemModel m,
ItemScoreAlgorithm algo) |
Modifier and Type | Method and Description |
---|---|
void |
globalScore(Collection<Long> queryItems,
MutableSparseVector output)
Score items in a vector based on a collection of items (a shopping basket).
|
globalScore, globalScore
protected final ItemItemModel model
@Nonnull protected final NeighborhoodScorer scorer
@Nonnull protected final ItemScoreAlgorithm algorithm
@Inject public ItemItemGlobalScorer(ItemItemModel m, ItemScoreAlgorithm algo)
public void globalScore(@Nonnull Collection<Long> queryItems, @Nonnull MutableSparseVector output)
GlobalItemScorer
queryItems
- The items to use as the query.output
- A vector whose key domain is the items to score.ItemScorer.score(long, MutableSparseVector)