Class InterCommunityDegreeGiniComplement.CommGiniUserReranker

java.lang.Object
Enclosing class:
InterCommunityDegreeGiniComplement<U>

protected class InterCommunityDegreeGiniComplement.CommGiniUserReranker
extends InterCommunityReranker.CommunityMetricUserReranker
Class that reranks an individual recommendation using Community Gini.
  • Field Summary

    Fields 
    Modifier and Type Field Description
    protected java.util.Map<java.lang.Integer,​java.lang.Integer> degrees
    Community degrees.
    protected EdgeOrientation orientation
    Edge orientation.
    protected double sum
    Sum of the community degrees.

    Fields inherited from class es.uam.eps.ir.relison.links.recommendation.reranking.local.communities.InterCommunityReranker.CommunityMetricUserReranker

    communities, communityGraph

    Fields inherited from class es.uam.eps.ir.relison.links.recommendation.reranking.local.LambdaReranker.LambdaUserReranker

    novMap, novStats, relStats
  • Constructor Summary

    Constructors 
    Constructor Description
    CommGiniUserReranker​(es.uam.eps.ir.ranksys.core.Recommendation<U,​U> recommendation, int maxLength, MultiGraph<java.lang.Integer> communityGraph, Communities<U> communities, EdgeOrientation orientation, java.util.Map<java.lang.Integer,​java.lang.Integer> degrees, double sum)
    Constructor
  • Method Summary

    Modifier and Type Method Description
    protected double nov​(org.ranksys.core.util.tuples.Tuple2od<U> tpld)
    Returns the novelty score of an item.
    protected void update​(org.ranksys.core.util.tuples.Tuple2od<U> tpld)  

    Methods inherited from class es.uam.eps.ir.relison.links.recommendation.reranking.local.LambdaReranker.LambdaUserReranker

    selectItem, value

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • sum

      protected double sum
      Sum of the community degrees.
    • degrees

      protected java.util.Map<java.lang.Integer,​java.lang.Integer> degrees
      Community degrees.
    • orientation

      protected EdgeOrientation orientation
      Edge orientation.
  • Constructor Details

    • CommGiniUserReranker

      public CommGiniUserReranker​(es.uam.eps.ir.ranksys.core.Recommendation<U,​U> recommendation, int maxLength, MultiGraph<java.lang.Integer> communityGraph, Communities<U> communities, EdgeOrientation orientation, java.util.Map<java.lang.Integer,​java.lang.Integer> degrees, double sum)
      Constructor
      Parameters:
      recommendation - the recommendation to be reranked
      maxLength - the maximum length of the reranked list.
      communityGraph - the community graph.
      communities - the communities
      orientation - the orientation of the edges.
      degrees - the degrees for each community.
      sum - the sum of the degrees.
  • Method Details

    • nov

      protected double nov​(org.ranksys.core.util.tuples.Tuple2od<U> tpld)
      Description copied from class: LambdaReranker.LambdaUserReranker
      Returns the novelty score of an item.
      Specified by:
      nov in class LambdaReranker.LambdaUserReranker
      Parameters:
      tpld - item-relevance pair
      Returns:
      the novelty of the item
    • update

      protected void update​(org.ranksys.core.util.tuples.Tuple2od<U> tpld)