All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
EdgeScoreNormalizer.h
Go to the documentation of this file.
1 /*
2  * EdgeScoreNormalizer.h
3  *
4  * Created on: 18.11.2014
5  * Author: Michael Hamann
6  */
7 
8 #ifndef EDGESCORENORMALIZER_H
9 #define EDGESCORENORMALIZER_H
10 
11 #include "../graph/Graph.h"
12 #include "EdgeScore.h"
13 
14 namespace NetworKit {
15 
16 template <typename A>
17 class EdgeScoreNormalizer : public EdgeScore<double> {
18 
19 public:
20  EdgeScoreNormalizer(const Graph &G, const std::vector<A> &score, bool invert = false, double lower = 0, double upper = 1.0);
21 
22  virtual double score(edgeid eid) override;
23  virtual double score(node u, node v) override;
24  virtual void run() override;
25 
26 private:
27  const std::vector<A> &input;
28  bool invert;
29  double lower, upper;
30 };
31 
32 }
33 
34 #endif /* EDGESCORENORMALIZER_H */
index edgeid
Definition: Globals.h:25
virtual double score(edgeid eid) override
Get the edge score of the edge with the given edge id.
Definition: EdgeScoreNormalizer.cpp:46
const Graph & G
Definition: EdgeScore.h:43
Definition: EdgeScoreNormalizer.h:17
virtual void run() override
Compute the edge score.
Definition: EdgeScoreNormalizer.cpp:10
index node
Definition: Globals.h:23
A graph (with optional weights) and parallel iterator methods.
Definition: Graph.h:79
EdgeScoreNormalizer(const Graph &G, const std::vector< A > &score, bool invert=false, double lower=0, double upper=1.0)
Definition: EdgeScoreNormalizer.cpp:6
Abstract base class for an edge score.
Definition: EdgeScore.h:20