Class RecommenderEvaluatorMappingExtensions
Extensions methods for the IRecommenderEvaluatorMapping<TInstanceSource, TUser, TItem, TRating> interface.
Inherited Members
Namespace: Microsoft.ML.Probabilistic.Learners.Mappings
Assembly: Microsoft.ML.Probabilistic.Learners.Recommender.dll
Syntax
public static class RecommenderEvaluatorMappingExtensions
Methods
GetItemsRatedBySameUsers<TInstanceSource, TUser, TItem, TRating>(IRecommenderEvaluatorMapping<TInstanceSource, TUser, TItem, TRating>, TInstanceSource, TItem)
Finds all the items which have been rated by the same user as queryItem.
Declaration
public static Dictionary<TItem, List<TUser>> GetItemsRatedBySameUsers<TInstanceSource, TUser, TItem, TRating>(this IRecommenderEvaluatorMapping<TInstanceSource, TUser, TItem, TRating> mapping, TInstanceSource instanceSource, TItem queryItem)
Parameters
| Type | Name | Description |
|---|---|---|
| IRecommenderEvaluatorMapping<TInstanceSource, TUser, TItem, TRating> | mapping | The mapping. |
| TInstanceSource | instanceSource | The instance source with items. |
| TItem | queryItem | The query item. |
Returns
| Type | Description |
|---|---|
| Dictionary<TItem, List<TUser>> | A dictionary which maps items from the |
Type Parameters
| Name | Description |
|---|---|
| TInstanceSource | The type of a source of instances. |
| TUser | The type of a user. |
| TItem | The type of an item. |
| TRating | The type of a rating. |
GetUsersWhoRatedSameItems<TInstanceSource, TUser, TItem, TRating>(IRecommenderEvaluatorMapping<TInstanceSource, TUser, TItem, TRating>, TInstanceSource, TUser)
Finds all the users who have rated the same item as queryUser.
Declaration
public static Dictionary<TUser, List<TItem>> GetUsersWhoRatedSameItems<TInstanceSource, TUser, TItem, TRating>(this IRecommenderEvaluatorMapping<TInstanceSource, TUser, TItem, TRating> mapping, TInstanceSource instanceSource, TUser queryUser)
Parameters
| Type | Name | Description |
|---|---|---|
| IRecommenderEvaluatorMapping<TInstanceSource, TUser, TItem, TRating> | mapping | The mapping. |
| TInstanceSource | instanceSource | The instance source with items. |
| TUser | queryUser | The query user. |
Returns
| Type | Description |
|---|---|
| Dictionary<TUser, List<TItem>> | A dictionary which maps users from the |
Type Parameters
| Name | Description |
|---|---|
| TInstanceSource | The type of a source of instances. |
| TUser | The type of a user. |
| TItem | The type of an item. |
| TRating | The type of a rating. |