Galois
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
GraphHelpers.h File Reference
#include <cassert>
#include <vector>
#include <boost/iterator/counting_iterator.hpp>
#include "galois/config.h"
#include "galois/gIO.h"

Go to the source code of this file.

Namespaces

 galois
 The Galois namespace containing all Galois structures and functions.
 
 galois::graphs
 Parallel data graph structures in Galois.
 

Functions

template<typename PrefixSumType , typename NodeType = uint64_t>
auto galois::graphs::divideNodesBinarySearch (NodeType numNodes, uint64_t numEdges, size_t nodeWeight, size_t edgeWeight, size_t id, size_t total, PrefixSumType &edgePrefixSum, std::vector< unsigned > scaleFactor=std::vector< unsigned >(), uint64_t edgeOffset=0, uint64_t nodeOffset=0)
 Returns 2 ranges (one for nodes, one for edges) for a particular division. More...
 
template<typename GraphTy >
std::vector< uint32_t > galois::graphs::determineUnitRangesFromGraph (GraphTy &graph, uint32_t unitsToSplit, uint32_t nodeAlpha=0)
 Determines node division ranges for all nodes in a graph and returns it in an offset vector. More...
 
template<typename GraphTy >
std::vector< uint32_t > galois::graphs::determineUnitRangesFromGraph (GraphTy &graph, uint32_t unitsToSplit, uint32_t beginNode, uint32_t endNode, uint32_t nodeAlpha=0)
 Determines node division ranges for a given range of nodes and returns it as an offset vector. More...
 
template<typename VectorTy >
std::vector< uint32_t > galois::graphs::determineUnitRangesFromPrefixSum (uint32_t unitsToSplit, VectorTy &edgePrefixSum, uint32_t nodeAlpha=0)
 Uses the divideByNode function (which is binary search based) to divide nodes among units using a provided prefix sum. More...
 
template<typename VectorTy >
std::vector< uint32_t > galois::graphs::determineUnitRangesFromPrefixSum (uint32_t unitsToSplit, VectorTy &edgePrefixSum, uint32_t beginNode, uint32_t endNode, uint32_t nodeAlpha=0)
 Uses the divideByNode function (which is binary search based) to divide nodes among units using a provided prefix sum. More...