public abstract class BatchItemSimilarities extends Object
| Modifier | Constructor and Description |
|---|---|
protected |
BatchItemSimilarities(ItemBasedRecommender recommender,
int similarItemsPerItem) |
| Modifier and Type | Method and Description |
|---|---|
abstract int |
computeItemSimilarities(int degreeOfParallelism,
int maxDurationInHours,
SimilarItemsWriter writer) |
protected ItemBasedRecommender |
getRecommender() |
protected int |
getSimilarItemsPerItem() |
protected BatchItemSimilarities(ItemBasedRecommender recommender, int similarItemsPerItem)
recommender - recommender to usesimilarItemsPerItem - number of similar items to compute per itemprotected ItemBasedRecommender getRecommender()
protected int getSimilarItemsPerItem()
public abstract int computeItemSimilarities(int degreeOfParallelism,
int maxDurationInHours,
SimilarItemsWriter writer)
throws IOException
degreeOfParallelism - number of threads to use for the computationmaxDurationInHours - maximum duration of the computationwriter - SimilarItemsWriter used to persist the resultsIOExceptionRuntimeException - if the computation takes longer than maxDurationInHoursCopyright © 2008–2017 The Apache Software Foundation. All rights reserved.