Defined in File LinkPredictor.hpp
public NetworKit::AdamicAdarIndex
(Class AdamicAdarIndex)
public NetworKit::AdjustedRandIndex
(Class AdjustedRandIndex)
public NetworKit::AlgebraicDistanceIndex
(Class AlgebraicDistanceIndex)
public NetworKit::CommonNeighborsIndex
(Class CommonNeighborsIndex)
public NetworKit::JaccardIndex
(Class JaccardIndex)
public NetworKit::KatzIndex
(Class KatzIndex)
public NetworKit::NeighborhoodDistanceIndex
(Class NeighborhoodDistanceIndex)
public NetworKit::NeighborsMeasureIndex
(Class NeighborsMeasureIndex)
public NetworKit::PreferentialAttachmentIndex
(Class PreferentialAttachmentIndex)
public NetworKit::ResourceAllocationIndex
(Class ResourceAllocationIndex)
public NetworKit::SameCommunityIndex
(Class SameCommunityIndex)
public NetworKit::TotalNeighborsIndex
(Class TotalNeighborsIndex)
public NetworKit::UDegreeIndex
(Class UDegreeIndex)
public NetworKit::VDegreeIndex
(Class VDegreeIndex)
Abstract base class for link predictors.
Subclassed by NetworKit::AdamicAdarIndex, NetworKit::AdjustedRandIndex, NetworKit::AlgebraicDistanceIndex, NetworKit::CommonNeighborsIndex, NetworKit::JaccardIndex, NetworKit::KatzIndex, NetworKit::NeighborhoodDistanceIndex, NetworKit::NeighborsMeasureIndex, NetworKit::PreferentialAttachmentIndex, NetworKit::ResourceAllocationIndex, NetworKit::SameCommunityIndex, NetworKit::TotalNeighborsIndex, NetworKit::UDegreeIndex, NetworKit::VDegreeIndex
Public Functions
Default destructor.
Sets the graph to work on.
newGraph – The graph to work on
Returns a score indicating the likelihood of a future link between the given nodes. Prior to calling this method a graph should be provided through the constructor or by calling setGraph. Note that only undirected graphs are accepted. There is also no lower or upper bound for scores and the actual range of values depends on the specific link predictor implementation. In case u == v a 0 is returned. If suitable this method might make use of parallelization to enhance performance.
u – First node in graph
v – Second node in graph
a prediction-score indicating the likelihood of a future link between the given nodes
Executes the run-method on al given nodePairs and returns a vector of predictions. The result is a vector of pairs where the first element is the node-pair and it’s second element the corresponding score generated by the run-method. The method makes use of parallelization.
nodePairs – Node-pairs to run the predictor on
a vector of pairs containing the given node-pair as the first element and it’s corresponding score as the second element. The vector is sorted ascendingly by node-pair
Runs the link predictor on all currently unconnected node-pairs. Possible self-loops are also excluded. The method makes use of parallelization.
a vector of pairs containing all currently unconnected node-pairs as the first elements and the corresponding scores as the second elements. The vector is sorted ascendingly by node-pair