PPL Logo

libs/ck-libs/metis/programs/io.c File Reference

Go to the source code of this file.

Functions

graph_tReadGraph (params_t *params)
mesh_tReadMesh (params_t *params)
void ReadTPwgts (params_t *params, idx_t ncon)
void ReadPOVector (graph_t *graph, char *filename, idx_t *vector)
void WritePartition (char *fname, idx_t *part, idx_t n, idx_t nparts)
void WriteMeshPartition (char *fname, idx_t nparts, idx_t ne, idx_t *epart, idx_t nn, idx_t *npart)
void WritePermutation (char *fname, idx_t *iperm, idx_t n)
void WriteGraph (graph_t *graph, char *filename)


Function Documentation

graph_t* ReadGraph ( params_t params  ) 

This function reads in a sparse graph

Definition at line 22 of file io.c.

References graph_t::adjncy, adjncy, graph_t::adjwgt, adjwgt, CreateGraph(), errexit(), params_t::filename, gk_fclose(), gk_fexists(), gk_fopen(), gk_free(), gk_getline(), PUP::l, graph_t::ncon, ncon, graph_t::nedges, graph_t::nvtxs, graph_t::vsize, vsize, graph_t::vwgt, vwgt, graph_t::xadj, and xadj.

Referenced by main().

Here is the call graph for this function:

Here is the caller graph for this function:

mesh_t* ReadMesh ( params_t params  ) 

This function reads in a mesh

Definition at line 178 of file io.c.

References CreateMesh(), mesh_t::eind, eind, mesh_t::eptr, eptr, errexit(), mesh_t::ewgt, params_t::filename, gk_fclose(), gk_fexists(), gk_fopen(), gk_free(), gk_getfilestats(), gk_getline(), PUP::l, mesh, mesh_t::ncon, ncon, mesh_t::ne, and mesh_t::nn.

Referenced by main().

Here is the call graph for this function:

Here is the caller graph for this function:

void ReadTPwgts ( params_t params,
idx_t  ncon 
)

This function reads in the target partition weights. If no file is specified the weights are set to 1/nparts

Definition at line 275 of file io.c.

References errexit(), free(), gk_fclose(), gk_fexists(), gk_fopen(), gk_free(), gk_getline(), gk_strchr_replace(), nparts, params_t::nparts, params_t::tpwgts, and params_t::tpwgtsfile.

Referenced by main().

Here is the call graph for this function:

Here is the caller graph for this function:

void ReadPOVector ( graph_t graph,
char *  filename,
idx_t vector 
)

This function reads in a partition/ordering vector

Definition at line 407 of file io.c.

References errexit(), gk_fclose(), gk_fopen(), and graph_t::nvtxs.

Referenced by main().

Here is the call graph for this function:

Here is the caller graph for this function:

void WritePartition ( char *  fname,
idx_t part,
idx_t  n,
idx_t  nparts 
)

This function writes out the partition vector

Definition at line 425 of file io.c.

References gk_fclose(), and gk_fopen().

Referenced by main().

Here is the call graph for this function:

Here is the caller graph for this function:

void WriteMeshPartition ( char *  fname,
idx_t  nparts,
idx_t  ne,
idx_t epart,
idx_t  nn,
idx_t npart 
)

This function writes out the partition vectors for a mesh

Definition at line 445 of file io.c.

References gk_fclose(), and gk_fopen().

Referenced by main().

Here is the call graph for this function:

Here is the caller graph for this function:

void WritePermutation ( char *  fname,
idx_t iperm,
idx_t  n 
)

This function writes out the permutation vector

Definition at line 477 of file io.c.

References gk_fclose(), and gk_fopen().

Referenced by main().

Here is the call graph for this function:

Here is the caller graph for this function:

void WriteGraph ( graph_t graph,
char *  filename 
)

This function writes a graph into a file

Definition at line 497 of file io.c.

References graph_t::adjncy, adjncy, graph_t::adjwgt, adjwgt, gk_fclose(), gk_fopen(), graph_t::ncon, ncon, graph_t::nvtxs, graph_t::vsize, vsize, graph_t::vwgt, vwgt, graph_t::xadj, and xadj.

Referenced by main().

Here is the call graph for this function:

Here is the caller graph for this function:


Generated on Mon Sep 21 08:09:00 2020 for Charm++ by  doxygen 1.5.5