COMBINATORIAL_BLAS  1.6
combblas::SpHelper Class Reference

#include <SpHelper.h>

Static Public Member Functions

template<typename T >
static std::vector< size_t > find_order (const std::vector< T > &values)
 
template<typename IT1 , typename NT1 , typename IT2 , typename NT2 >
static void push_to_vectors (std::vector< IT1 > &rows, std::vector< IT1 > &cols, std::vector< NT1 > &vals, IT2 ii, IT2 jj, NT2 vv, int symmetric, bool onebased=true)
 
static void ProcessLinesWithStringKeys (std::vector< std::map< std::string, uint64_t > > &allkeys, std::vector< std::string > &lines, int nprocs)
 
template<typename IT1 , typename NT1 >
static void ProcessStrLinesNPermute (std::vector< IT1 > &rows, std::vector< IT1 > &cols, std::vector< NT1 > &vals, std::vector< std::string > &lines, std::map< std::string, uint64_t > &ultperm)
 
template<typename IT1 , typename NT1 >
static void ProcessLines (std::vector< IT1 > &rows, std::vector< IT1 > &cols, std::vector< NT1 > &vals, std::vector< std::string > &lines, int symmetric, int type, bool onebased=true)
 
template<typename T >
static const T * p2a (const std::vector< T > &v)
 
template<typename T >
static T * p2a (std::vector< T > &v)
 
template<typename _ForwardIterator >
static bool is_sorted (_ForwardIterator __first, _ForwardIterator __last)
 
template<typename _ForwardIterator , typename _StrictWeakOrdering >
static bool is_sorted (_ForwardIterator __first, _ForwardIterator __last, _StrictWeakOrdering __comp)
 
template<typename _ForwardIter , typename T >
static void iota (_ForwardIter __first, _ForwardIter __last, T __val)
 
template<typename In , typename Out , typename UnPred >
static Out copyIf (In first, In last, Out result, UnPred pred)
 
template<typename T , typename I1 , typename I2 >
static T ** allocate2D (I1 m, I2 n)
 
template<typename T , typename I >
static void deallocate2D (T **array, I m)
 
template<typename SR , typename NT1 , typename NT2 , typename IT , typename OVT >
static IT Popping (NT1 *numA, NT2 *numB, StackEntry< OVT, std::pair< IT, IT > > *multstack, IT &cnz, KNHeap< std::pair< IT, IT >, IT > &sHeap, Isect< IT > *isect1, Isect< IT > *isect2)
 
template<typename IT , typename NT1 , typename NT2 >
static void SpIntersect (const Dcsc< IT, NT1 > &Adcsc, const Dcsc< IT, NT2 > &Bdcsc, Isect< IT > *&cols, Isect< IT > *&rows, Isect< IT > *&isect1, Isect< IT > *&isect2, Isect< IT > *&itr1, Isect< IT > *&itr2)
 
template<typename SR , typename IT , typename NT1 , typename NT2 , typename OVT >
static IT SpCartesian (const Dcsc< IT, NT1 > &Adcsc, const Dcsc< IT, NT2 > &Bdcsc, IT kisect, Isect< IT > *isect1, Isect< IT > *isect2, StackEntry< OVT, std::pair< IT, IT > > *&multstack)
 
template<typename SR , typename IT , typename NT1 , typename NT2 , typename OVT >
static IT SpColByCol (const Dcsc< IT, NT1 > &Adcsc, const Dcsc< IT, NT2 > &Bdcsc, IT nA, StackEntry< OVT, std::pair< IT, IT > > *&multstack)
 
template<typename NT , typename IT >
static void ShrinkArray (NT *&array, IT newsize)
 
template<typename NT , typename IT >
static void DoubleStack (StackEntry< NT, std::pair< IT, IT > > *&multstack, IT &cnzmax, IT add)
 
template<typename IT >
static bool first_compare (std::pair< IT, IT > pair1, std::pair< IT, IT > pair2)
 

Detailed Description

Definition at line 52 of file SpHelper.h.

Member Function Documentation

◆ allocate2D()

template<typename T , typename I1 , typename I2 >
static T** combblas::SpHelper::allocate2D ( I1  m,
I2  n 
)
inlinestatic

Definition at line 241 of file SpHelper.h.

◆ copyIf()

template<typename In , typename Out , typename UnPred >
static Out combblas::SpHelper::copyIf ( In  first,
In  last,
Out  result,
UnPred  pred 
)
inlinestatic

Definition at line 232 of file SpHelper.h.

◆ deallocate2D()

template<typename T , typename I >
static void combblas::SpHelper::deallocate2D ( T **  array,
m 
)
inlinestatic

Definition at line 249 of file SpHelper.h.

◆ DoubleStack()

template<typename NT , typename IT >
static void combblas::SpHelper::DoubleStack ( StackEntry< NT, std::pair< IT, IT > > *&  multstack,
IT &  cnzmax,
IT  add 
)
inlinestatic

Definition at line 284 of file SpHelper.h.

◆ find_order()

template<typename T >
static std::vector<size_t> combblas::SpHelper::find_order ( const std::vector< T > &  values)
inlinestatic

Definition at line 57 of file SpHelper.h.

◆ first_compare()

template<typename IT >
static bool combblas::SpHelper::first_compare ( std::pair< IT, IT >  pair1,
std::pair< IT, IT >  pair2 
)
inlinestatic

Definition at line 295 of file SpHelper.h.

◆ iota()

template<typename _ForwardIter , typename T >
static void combblas::SpHelper::iota ( _ForwardIter  __first,
_ForwardIter  __last,
__val 
)
inlinestatic

Definition at line 226 of file SpHelper.h.

◆ is_sorted() [1/2]

template<typename _ForwardIterator >
static bool combblas::SpHelper::is_sorted ( _ForwardIterator  __first,
_ForwardIterator  __last 
)
inlinestatic

Definition at line 202 of file SpHelper.h.

◆ is_sorted() [2/2]

template<typename _ForwardIterator , typename _StrictWeakOrdering >
static bool combblas::SpHelper::is_sorted ( _ForwardIterator  __first,
_ForwardIterator  __last,
_StrictWeakOrdering  __comp 
)
inlinestatic

Definition at line 214 of file SpHelper.h.

◆ p2a() [1/2]

template<typename T >
static const T* combblas::SpHelper::p2a ( const std::vector< T > &  v)
inlinestatic

Definition at line 187 of file SpHelper.h.

◆ p2a() [2/2]

template<typename T >
static T* combblas::SpHelper::p2a ( std::vector< T > &  v)
inlinestatic

Definition at line 194 of file SpHelper.h.

◆ Popping()

template<typename SR , typename NT1 , typename NT2 , typename IT , typename OVT >
IT combblas::SpHelper::Popping ( NT1 *  numA,
NT2 *  numB,
StackEntry< OVT, std::pair< IT, IT > > *  multstack,
IT &  cnz,
KNHeap< std::pair< IT, IT >, IT > &  sHeap,
Isect< IT > *  isect1,
Isect< IT > *  isect2 
)
static

Pop an element, do the numerical semiring multiplication & insert the result into multstack

Definition at line 307 of file SpHelper.h.

◆ ProcessLines()

template<typename IT1 , typename NT1 >
static void combblas::SpHelper::ProcessLines ( std::vector< IT1 > &  rows,
std::vector< IT1 > &  cols,
std::vector< NT1 > &  vals,
std::vector< std::string > &  lines,
int  symmetric,
int  type,
bool  onebased = true 
)
inlinestatic

Definition at line 147 of file SpHelper.h.

◆ ProcessLinesWithStringKeys()

static void combblas::SpHelper::ProcessLinesWithStringKeys ( std::vector< std::map< std::string, uint64_t > > &  allkeys,
std::vector< std::string > &  lines,
int  nprocs 
)
inlinestatic

Definition at line 93 of file SpHelper.h.

◆ ProcessStrLinesNPermute()

template<typename IT1 , typename NT1 >
static void combblas::SpHelper::ProcessStrLinesNPermute ( std::vector< IT1 > &  rows,
std::vector< IT1 > &  cols,
std::vector< NT1 > &  vals,
std::vector< std::string > &  lines,
std::map< std::string, uint64_t > &  ultperm 
)
inlinestatic

Definition at line 123 of file SpHelper.h.

◆ push_to_vectors()

template<typename IT1 , typename NT1 , typename IT2 , typename NT2 >
static void combblas::SpHelper::push_to_vectors ( std::vector< IT1 > &  rows,
std::vector< IT1 > &  cols,
std::vector< NT1 > &  vals,
IT2  ii,
IT2  jj,
NT2  vv,
int  symmetric,
bool  onebased = true 
)
inlinestatic

Definition at line 75 of file SpHelper.h.

◆ ShrinkArray()

template<typename NT , typename IT >
static void combblas::SpHelper::ShrinkArray ( NT *&  array,
IT  newsize 
)
inlinestatic

Definition at line 274 of file SpHelper.h.

◆ SpCartesian()

template<typename SR , typename IT , typename NT1 , typename NT2 , typename OVT >
IT combblas::SpHelper::SpCartesian ( const Dcsc< IT, NT1 > &  Adcsc,
const Dcsc< IT, NT2 > &  Bdcsc,
IT  kisect,
Isect< IT > *  isect1,
Isect< IT > *  isect2,
StackEntry< OVT, std::pair< IT, IT > > *&  multstack 
)
static

Performs cartesian product on the dcsc structures. Indices to perform the product are given by isect1 and isect2 arrays Returns the "actual" number of elements in the merged stack Bdcsc is "already transposed" (i.e. Bdcsc->ir gives column indices, and Bdcsc->jc gives row indices)

Definition at line 386 of file SpHelper.h.

◆ SpColByCol()

template<typename SR , typename IT , typename NT1 , typename NT2 , typename OVT >
IT combblas::SpHelper::SpColByCol ( const Dcsc< IT, NT1 > &  Adcsc,
const Dcsc< IT, NT2 > &  Bdcsc,
IT  nA,
StackEntry< OVT, std::pair< IT, IT > > *&  multstack 
)
static

Definition at line 449 of file SpHelper.h.

◆ SpIntersect()

template<typename IT , typename NT1 , typename NT2 >
void combblas::SpHelper::SpIntersect ( const Dcsc< IT, NT1 > &  Adcsc,
const Dcsc< IT, NT2 > &  Bdcsc,
Isect< IT > *&  cols,
Isect< IT > *&  rows,
Isect< IT > *&  isect1,
Isect< IT > *&  isect2,
Isect< IT > *&  itr1,
Isect< IT > *&  itr2 
)
static

Finds the intersecting row indices of Adcsc and col indices of Bdcsc

Parameters

Definition at line 346 of file SpHelper.h.


The documentation for this class was generated from the following file: