Entity Matching by Similarity Join
 
Loading...
Searching...
No Matches
block.h
Go to the documentation of this file.
1/*
2 * author: Yunqi Li
3 * contact: liyunqixa@gmail.com
4 */
5/*
6 * configs for blocker
7 * this file can only be included by files inside "blocker" folder
8 */
9#ifndef _BLOCK_H_
10#define _BLOCK_H_
11
13#include "blocker/knn_blocker.h"
15#include <iomanip>
16#include <omp.h>
17
18// only in block.cc
19// global variables
20extern ui num_word;
21extern std::vector<TokenizerType> tok_type;
22extern std::vector<ui> q;
23
24
25class Block
26{
27public:
28 Block() = default;
29 ~Block() = default;
30 Block(const Block &other) = delete;
31 Block(Block &&other) = delete;
32
33public:
34 static void clearBuffers();
35
36public:
37 static void prepareRecordsRS(ui columnA, ui columnB, TokenizerType tt, ui q);
38 static void prepareRecordsSelf(ui columnA, TokenizerType tt, ui q);
39 static void sortColumns();
40 static void showPara(int jt, int js, uint64_t topK, const std::string &topKattr,
41 const std::string &attrType, const std::string &pathTableA,
42 const std::string &pathTableB, const std::string &pathGold,
43 const std::string &pathRule, int tableSize);
44
45 // pre-process & post-process
46 static void readCSVTables(int isRS, const std::string &pathTableA, const std::string &pathTableB,
47 const std::string &pathGold);
48 static void readRules(const std::string &pathRule);
49 static void tokenize(int isRS);
50 static void getRecall(int isRS);
51 static void getRecall4Rules(int isRS);
52};
53
54
55#endif // _BLOCK_CONFIG_H_
std::vector< ui > q
Definition block.cc:9
std::vector< TokenizerType > tok_type
Definition block.cc:8
ui num_word
Definition block.cc:7
Definition block.h:26
static void getRecall(int isRS)
Definition block.cc:276
static void getRecall4Rules(int isRS)
Definition block.cc:325
static void readCSVTables(int isRS, const std::string &pathTableA, const std::string &pathTableB, const std::string &pathGold)
Definition block.cc:148
static void showPara(int jt, int js, uint64_t topK, const std::string &topKattr, const std::string &attrType, const std::string &pathTableA, const std::string &pathTableB, const std::string &pathGold, const std::string &pathRule, int tableSize)
Definition block.cc:128
~Block()=default
static void readRules(const std::string &pathRule)
Definition block.cc:189
static void prepareRecordsSelf(ui columnA, TokenizerType tt, ui q)
Definition block.cc:59
Block()=default
Block(Block &&other)=delete
static void sortColumns()
Definition block.cc:79
static void clearBuffers()
Definition block.cc:12
Block(const Block &other)=delete
static void prepareRecordsRS(ui columnA, ui columnB, TokenizerType tt, ui q)
Definition block.cc:40
static void tokenize(int isRS)
Definition block.cc:204
TokenizerType
Definition type.h:39
unsigned int ui
Definition type.h:8