Package org.nlpub.watset.graph
Class NodeWeightings.LabelNodeWeighting<V,E>
java.lang.Object
org.nlpub.watset.graph.NodeWeightings.LabelNodeWeighting<V,E>
- Type Parameters:
V- the type of nodes in the graphE- the type of edges in the graph
- All Implemented Interfaces:
NodeWeighting<V,E>
- Enclosing class:
- NodeWeightings
public static class NodeWeightings.LabelNodeWeighting<V,E>
extends Object
implements NodeWeighting<V,E>
A trivial and not particularly useful node weighting approach that
assigns the current node label as the weight.
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
LabelNodeWeighting
public LabelNodeWeighting()
-
-
Method Details
-
apply
Description copied from interface:NodeWeightingCompute the weight of the node in the neighborhood graph.- Specified by:
applyin interfaceNodeWeighting<V,E> - Parameters:
graph- the neighborhood graphlabels- the map of graph nodes to their labelsnode- the target nodeneighbor- the neighboring node- Returns:
- the weight of the node in the neighborhood
-