Go to the source code of this file.
Functions | |
void | RefineKWay (ctrl_t *ctrl, graph_t *orggraph, graph_t *graph) |
void | AllocateKWayPartitionMemory (ctrl_t *ctrl, graph_t *graph) |
void | ComputeKWayPartitionParams (ctrl_t *ctrl, graph_t *graph) |
void | ProjectKWayPartition (ctrl_t *ctrl, graph_t *graph) |
void | ComputeKWayBoundary (ctrl_t *ctrl, graph_t *graph, idx_t bndtype) |
void | ComputeKWayVolGains (ctrl_t *ctrl, graph_t *graph) |
int | IsBalanced (ctrl_t *ctrl, graph_t *graph, real_t ffactor) |
Definition in file kwayrefine.c.
This function is the entry point of cut-based refinement
Definition at line 17 of file kwayrefine.c.
References ComputeKWayBoundary(), ComputeKWayPartitionParams(), ctrl_t::contig, ctrl_t::dbglvl, EliminateComponents(), EliminateSubDomainEdges(), FindPartitionInducedComponents(), graph_t::finer, Greedy_KWayOptimize(), IsBalanced(), METIS_DBG_TIME, ctrl_t::minconn, ctrl_t::niter, ctrl_t::nparts, ProjectKWayPartition(), ctrl_t::ProjectTmr, ctrl_t::RefTmr, ctrl_t::UncoarsenTmr, graph_t::vwgt, and graph_t::where.
Referenced by MlevelKWayPartitioning().
This function allocates memory for the k-way cut-based refinement
Definition at line 116 of file kwayrefine.c.
References graph_t::bndind, graph_t::bndptr, graph_t::ckrinfo, gk_errexit(), gk_malloc(), METIS_OBJTYPE_CUT, METIS_OBJTYPE_VOL, graph_t::ncon, ctrl_t::nparts, graph_t::nvtxs, ctrl_t::objtype, graph_t::pwgts, graph_t::vkrinfo, and graph_t::where.
Referenced by MlevelKWayPartitioning(), and ProjectKWayPartition().
This function computes the initial id/ed for cut-based partitioning
Definition at line 149 of file kwayrefine.c.
References graph_t::adjncy, adjncy, graph_t::adjwgt, adjwgt, graph_t::bndind, graph_t::bndptr, CheckBnd2(), graph_t::ckrinfo, ctrl_t::cnbrpool, cnbrpoolGetNext(), cnbrpoolReset(), ComputeKWayVolGains(), ComputeVolume(), cnbr_t::ed, ckrinfo_t::ed, gk_errexit(), vnbr_t::gv, ckrinfo_t::id, vkrinfo_t::inbr, ckrinfo_t::inbr, PUP::l, METIS_OBJTYPE_CUT, METIS_OBJTYPE_VOL, graph_t::mincut, graph_t::minvol, graph_t::nbnd, graph_t::ncon, ncon, vnbr_t::ned, vkrinfo_t::ned, vkrinfo_t::nid, vkrinfo_t::nnbrs, ckrinfo_t::nnbrs, ctrl_t::nparts, nparts, graph_t::nvtxs, ctrl_t::objtype, vnbr_t::pid, cnbr_t::pid, graph_t::pwgts, graph_t::vkrinfo, ctrl_t::vnbrpool, vnbrpoolGetNext(), vnbrpoolReset(), graph_t::vwgt, vwgt, graph_t::where, where, graph_t::xadj, and xadj.
Referenced by RefineKWay().
This function projects a partition, and at the same time computes the parameters for refinement.
Definition at line 315 of file kwayrefine.c.
References graph_t::adjncy, adjncy, graph_t::adjwgt, adjwgt, AllocateKWayPartitionMemory(), graph_t::bndind, graph_t::bndptr, CheckBnd2(), graph_t::ckrinfo, graph_t::cmap, ctrl_t::cnbrpool, cnbrpoolGetNext(), cnbrpoolReset(), graph_t::coarser, ComputeKWayVolGains(), ComputeVolume(), cnbr_t::ed, ckrinfo_t::ed, FreeGraph(), gk_errexit(), vnbr_t::gv, ckrinfo_t::id, vkrinfo_t::inbr, ckrinfo_t::inbr, iwspacemalloc(), METIS_OBJTYPE_CUT, METIS_OBJTYPE_VOL, graph_t::mincut, graph_t::minvol, graph_t::nbnd, ctrl_t::nbrpoolcpos, graph_t::ncon, vnbr_t::ned, vkrinfo_t::ned, vkrinfo_t::nid, vkrinfo_t::nnbrs, ckrinfo_t::nnbrs, ctrl_t::nparts, nparts, graph_t::nvtxs, ctrl_t::objtype, vnbr_t::pid, cnbr_t::pid, graph_t::pwgts, graph_t::vkrinfo, ctrl_t::vnbrpool, vnbrpoolGetNext(), vnbrpoolReset(), graph_t::where, where, graph_t::xadj, and xadj.
Referenced by RefineKWay().
This function computes the boundary definition for balancing.
Definition at line 507 of file kwayrefine.c.
References graph_t::bndind, graph_t::bndptr, graph_t::ckrinfo, ckrinfo_t::ed, gk_errexit(), vkrinfo_t::gv, ckrinfo_t::id, METIS_OBJTYPE_CUT, METIS_OBJTYPE_VOL, graph_t::nbnd, vkrinfo_t::ned, graph_t::nvtxs, ctrl_t::objtype, and graph_t::vkrinfo.
Referenced by RefineKWay().
This function computes the initial gains in the communication volume
Definition at line 562 of file kwayrefine.c.
References graph_t::adjncy, adjncy, graph_t::adjwgt, adjwgt, graph_t::bndind, graph_t::bndptr, vnbr_t::gv, vkrinfo_t::gv, vkrinfo_t::inbr, iwspacemalloc(), PUP::l, graph_t::minvol, graph_t::nbnd, vkrinfo_t::ned, vkrinfo_t::nid, vkrinfo_t::nnbrs, ctrl_t::nparts, nparts, graph_t::nvtxs, graph_t::vkrinfo, ctrl_t::vnbrpool, graph_t::vsize, vsize, graph_t::where, where, graph_t::xadj, and xadj.
Referenced by ComputeKWayPartitionParams(), and ProjectKWayPartition().
This function checks if the partition weights are within the balance contraints
Definition at line 666 of file kwayrefine.c.
References ComputeLoadImbalanceDiff(), ctrl_t::nparts, ctrl_t::pijbm, and ctrl_t::ubfactors.
Referenced by Greedy_McKWayCutOptimize(), Greedy_McKWayVolOptimize(), and RefineKWay().