1 #ifndef Snap_GraphCounter
2 #define Snap_GraphCounter
72 for(
int i=0; i<sg.
Len(); i++) printf(
"%d, ", sg[i].Val);
86 return G->
IsEdge(SrcNId, DstNId,
true);
THash< TUInt64, TUInt64 > m_graphMaps
int GetId(const int &i) const
uint64 GetCnt(const int &GraphId) const
THash< TUInt64, TUInt64 > m_graphCounters
void operator()(const PNGraph &G, const TIntV &sg)
TSizeTy Len() const
Returns the number of elements in the vector.
void operator()(const PNGraph &G, const TIntV &sg)
static void GetPermutations(TIntV &v, int start, TVec< TIntV > &perms)
static int getId(const PNGraph &G, const TIntV &sg)
const TDat & GetDat(const TKey &Key) const
void operator()(const PNGraph &G, const TIntV &sg)
TGHash< TUInt64 > & Graphs()
PNGraph GetGraph(const int &GraphId) const
THash< TUInt64, TUInt64 > & GraphCounters()
static void GetIsoGraphs(uint64 graphId, int nodes, TVec< PNGraph > &isoG)
static bool IsEdge(const PNGraph &G, int SrcNId, int DstNId)
static void GetNormalizedMap(const PNGraph &G, THash< TInt, TInt > &map)
unsigned long long uint64
static uint64 GraphId(const PNGraph &G)
bool IsEdge(const int &SrcNId, const int &DstNId, const bool &IsDir=true) const
Tests whether an edge from node IDs SrcNId to DstNId exists in the graph.
static void GetEdges(uint64 graphId, int nodes, TVec< TPair< int, int > > &edges)
static int getId(const PNGraph &G, const TIntV &sg)
static void GetNormalizedGraph(const PNGraph &G, PNGraph &nG)
TGHash< TUInt64 > m_graphs
static uint64 GetMinAndGraphIds(const TVec< PNGraph > &isoG, TVec< uint64 > &graphIds)
THash< TInt, TInt > m_graphMaps
THash< TInt, TUInt64 > m_graphCounters
static void GetIndGraph(const PNGraph &G, const TIntV &sg, PNGraph &indG)
void operator()(const PNGraph &G, const TIntV &sg)
static void GetGraph(uint64 graphId, int nodes, PNGraph &G)
const TKey & GetKey(const int &KeyId) const
TD34GraphCounter(int GraphSz)