benchmark_mps/make_planar/graphml_to_gml.cpp

28 lines
474 B
C++
Raw Normal View History

/* This code converts GraphML to gml
*
*/
#include <ogdf/fileformats/GraphIO.h>
#include <iostream>
using namespace ogdf;
int main(int argc, char* argv[])
{
string input_file = argv[1];
Graph G;
if (!GraphIO::read(G, input_file, GraphIO::readGraphML)) {
std::cerr << "Could not read input.gml" << std::endl;
return 1;
}
string output_file = argv[2];
GraphIO::write(G, output_file, GraphIO::writeGML);
return 0;
}