https://github.com/kit-parco/networkit
Tip revision: 0c7d9a0eb71a7d6e3131c311c402192797c1977b authored by maxv on 06 August 2015, 13:15:07 UTC
closing branch as the functionality has been merged into and further developed on the Dev branch.
closing branch as the functionality has been merged into and further developed on the Dev branch.
Tip revision: 0c7d9a0
LibDemo.cpp
#include <NetworKit/io/METISGraphReader.h>
#include <NetworKit/auxiliary/Log.h>
#include <NetworKit/community/PLM.h>
#include <iostream>
int main() {
std::cout << "simple demonstration of NetworKit as a library\n";
Aux::Log::Settings::setLogLevel(Aux::Log::LogLevel::info);
NetworKit::METISGraphReader reader;
NetworKit::Graph jazz = reader.read("./input/jazz.graph");
NetworKit::PLM plm(jazz,true);
plm.run();
NetworKit::Partition communities = plm.getPartition();
std::cout << communities.numberOfSubsets() << " communities have been found\n";
return 0;
}