-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathdetectorMultiFast.h
More file actions
65 lines (53 loc) · 1.88 KB
/
detectorMultiFast.h
File metadata and controls
65 lines (53 loc) · 1.88 KB
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
//
// Created by yuwzhang7 on 2021/10/18.
//
#ifndef PROGRAM_DETECTORMULTIFAST_H
#define PROGRAM_DETECTORMULTIFAST_H
#include <limits>
#include "params.h"
#include "data.h"
#include "inputAndOutput.h"
#include "multiTree.h"
#include "utils.h"
#include <algorithm>
#include <vector>
namespace SuperTAD { namespace multi {
class Discretization{
private:
SuperTAD::Data *_data = NULL;
double ****_tableT = NULL;
int ***_minStepF = NULL; // the searching result for each value in F
int ****_minIndexT = NULL; // the searching result for each value in T
int ****_tableStepIndexT = NULL; // the table storing the step index for each value in T
double **_tablestep = NULL; // the table storing the step size given start and end
double ****_sumofgcT = NULL; // the table storing the sum of gc (accurate value)
std::vector<Boundary> _boundaries;
public:
double ***_tableF = NULL; // Will be used in NeighborSearching
multi::Tree _multiTree;
Discretization(SuperTAD::Data &data);
~Discretization();
void execute();
void fillTable();
void multiSplit(int start, int end, int l, int h);
};
class NeighborSearch{
private:
SuperTAD::Data *_data;
multi::Tree _multiTree;
double *** _tableF;
std::vector<multi::TreeNode*> _nodeList; // include root
int _Nnodes = 0;
SuperTAD::Writer _writer;
double *****_table = NULL;
int *****_minIndex = NULL;
public:
NeighborSearch(SuperTAD::Data &data, multi::Tree *multiTree, double ***tableF);
~NeighborSearch();
void execute();
void fillTable();
int mapWin(int index) { return index + SuperTAD::_WINDOW_;};
void multiSplit(multi::TreeNode &Node, int s_win, int e_win);
};
} }
#endif //PROGRAM_DETECTORMULTIFAST_H