All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | List of all members
NetworKit::LocalDegreeScore Class Reference

Local Degree sparsification method. More...

#include <LocalDegreeScore.h>

Public Member Functions

 LocalDegreeScore (const Graph &G)
 
virtual void run () override
 Compute the edge score. More...
 
virtual double score (edgeid eid) override
 Get the edge score of the edge with the given edge id. More...
 
virtual double score (node u, node v) override
 Get the edge score of the given edge. More...
 
- Public Member Functions inherited from NetworKit::EdgeScore< double >
 EdgeScore (const Graph &G)
 
virtual std::vector< double > scores () const
 Get a vector containing the score for each edge in the graph. More...
 
- Public Member Functions inherited from NetworKit::Algorithm
 Algorithm ()
 Constructor to the algorithm base class. More...
 
virtual ~Algorithm ()=default
 Virtual default destructor. More...
 
bool hasFinished () const
 Indicates whether an algorithm has completed computation or not. More...
 
void assureFinished () const
 Assure that the algorithm has been run, throws a std::runtime_error otherwise. More...
 
virtual std::string toString () const
 Returns a string with the algorithm's name and its parameters, if there are any. More...
 
virtual bool isParallel () const
 

Additional Inherited Members

- Protected Attributes inherited from NetworKit::EdgeScore< double >
const GraphG
 
std::vector< double > scoreData
 
- Protected Attributes inherited from NetworKit::Algorithm
bool hasRun
 A boolean variable indicating whether an algorithm has finished its computation or not. More...
 

Detailed Description

Local Degree sparsification method.

See 'Structure-Preserving Sparsification of Social Networks' by Lindner, Staudt, Hamann.

Constructor & Destructor Documentation

NetworKit::LocalDegreeScore::LocalDegreeScore ( const Graph G)

Member Function Documentation

void NetworKit::LocalDegreeScore::run ( )
overridevirtual

Compute the edge score.

The top d^e edges (sorted by degree) are to be kept in the graph

By convention, we want to the edges with highest "similarity" or "cohesion" to have values close to 1, so we invert the range.

Reimplemented from NetworKit::EdgeScore< double >.

double NetworKit::LocalDegreeScore::score ( edgeid  eid)
overridevirtual

Get the edge score of the edge with the given edge id.

Reimplemented from NetworKit::EdgeScore< double >.

double NetworKit::LocalDegreeScore::score ( node  u,
node  v 
)
overridevirtual

Get the edge score of the given edge.

Reimplemented from NetworKit::EdgeScore< double >.


The documentation for this class was generated from the following files: