-
Notifications
You must be signed in to change notification settings - Fork 0
/
lwm_initAndCollect.h
137 lines (122 loc) · 4.31 KB
/
lwm_initAndCollect.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
/*
* lwm_initAndCollect.h
*
* Created on: Mar 27, 2018
* Author: pascal
*/
#ifndef LWM_INITANDCOLLECT_H_
#define LWM_INITANDCOLLECT_H_
#include "supportSet.h"
//int** getPostorders(struct Graph** db, int nGraphs);
int getDB(struct Graph*** db);
int getDBfromCanonicalStrings(struct Graph*** db, FILE* stream, size_t bufferSize, struct GraphPool* gp, struct ShallowGraphPool* sgp);
// should be static, but are required by lwmr_initAndCollect
int getFrequentVertices(struct Graph** db, int dbSize, struct Vertex* frequentVertices, struct GraphPool* gp);
struct ShallowGraph* edgeSearchTree2ShallowGraph(struct Vertex* frequentEdges, struct Graph** newVertices, struct GraphPool* gp, struct ShallowGraphPool* sgp);
struct SupportSet* getSupportSetsOfVerticesForPatternEnumeration(struct Graph** db, int nGraphs, struct Vertex* frequentVertices, struct GraphPool* gp, struct ShallowGraphPool* sgp);
struct IterativeBfsForForestsDataStructures {
struct Graph** db;
int** postorders;
struct Vertex* initialFrequentPatterns;
struct ShallowGraph* extensionEdges;
struct Graph* extensionEdgesVertexStore;
int nGraphs;
};
//struct SupportSet* getSupportSetsOfVertices(struct Graph** db, int** postoderDB, size_t nGraphs, struct Graph* h, int patternId);
//void getFrequentVerticesAndEdges(struct Graph** db, int nGraphs, size_t threshold, struct Vertex** frequentVertices, struct Vertex** frequentEdges, FILE* logStream, struct GraphPool* gp);
//struct SupportSet* createSingletonPatternSupportSetsForForestDB(struct Graph** db, int** postorders, int nGraphs, struct Vertex* frequentVertices, struct GraphPool* gp, struct ShallowGraphPool* sgp);
// inits and garbage collectors
size_t initFrequentTreeMiningForForestDB(// input
size_t threshold,
double importance,
// output
struct Vertex** initialFrequentPatterns,
struct SupportSet** supportSets,
struct ShallowGraph** extensionEdgeList,
void** dataStructures,
// printing
FILE* featureStream,
FILE* patternStream,
FILE* logStream,
// pools
struct GraphPool* gp,
struct ShallowGraphPool* sgp);
size_t initProbabilisticTreeMiningForGraphDB(// input
size_t threshold,
double importance,
// output
struct Vertex** initialFrequentPatterns,
struct SupportSet** supportSets,
struct ShallowGraph** extensionEdgeList,
void** dataStructures,
// printing
FILE* featureStream,
FILE* patternStream,
FILE* logStream,
// pools
struct GraphPool* gp,
struct ShallowGraphPool* sgp);
size_t initGlobalTreeEnumerationForGraphDB(// input
size_t threshold,
double importance,
// output
struct Vertex** initialFrequentPatterns,
struct SupportSet** supportSets,
struct ShallowGraph** extensionEdgeList,
void** dataStructures,
// printing
FILE* featureStream,
FILE* patternStream,
FILE* logStream,
// pools
struct GraphPool* gp,
struct ShallowGraphPool* sgp);
size_t initExactLocalEasyForGraphDB(// input
size_t threshold,
double importance,
// output
struct Vertex** initialFrequentPatterns,
struct SupportSet** supportSets,
struct ShallowGraph** extensionEdgeList,
void** dataStructures,
// printing
FILE* featureStream,
FILE* patternStream,
FILE* logStream,
// pools
struct GraphPool* gp,
struct ShallowGraphPool* sgp);
size_t initSampledLocalEasyForGraphDB(// input
size_t threshold,
double importance,
// output
struct Vertex** initialFrequentPatterns,
struct SupportSet** supportSets,
struct ShallowGraph** extensionEdgeList,
void** dataStructures,
// printing
FILE* featureStream,
FILE* patternStream,
FILE* logStream,
// pools
struct GraphPool* gp,
struct ShallowGraphPool* sgp);
size_t initPatternEnumeration(// input
size_t threshold,
double importance,
// output
struct Vertex** initialFrequentPatterns,
struct SupportSet** supportSets,
struct ShallowGraph** extensionEdgeList,
void** dataStructures,
// printing
FILE* featureStream,
FILE* patternStream,
FILE* logStream,
// pools
struct GraphPool* gp,
struct ShallowGraphPool* sgp);
void garbageCollectFrequentTreeMiningForForestDB(void** y, struct GraphPool* gp, struct ShallowGraphPool* sgp);
void garbageCollectLocalEasyForGraphDB(void** y, struct GraphPool* gp, struct ShallowGraphPool* sgp);
void garbageCollectPatternEnumeration(void** y, struct GraphPool* gp, struct ShallowGraphPool* sgp);
#endif /* LWM_INITANDCOLLECT_H_ */