81class TTKMERGETREETEMPORALREDUCTIONDECODING_EXPORT
92 bool OutputTrees =
true;
93 bool PlanarLayout =
false;
94 bool BranchDecompositionPlanarLayout =
false;
95 bool PathPlanarLayout =
false;
96 double BranchSpacing = 1.;
97 bool RescaleTreesIndividually =
false;
98 double DimensionSpacing = 1.;
99 int DimensionToShift = 0;
100 double ImportantPairs = 50.;
101 int MaximumImportantPairs = 0;
102 int MinimumImportantPairs = 0;
103 double ImportantPairsSpacing = 1.;
104 double NonImportantPairsSpacing = 1.;
105 double NonImportantPairsProximity = 0.05;
106 std::string ExcludeImportantPairsLower =
"";
107 std::string ExcludeImportantPairsHigher =
"";
113 std::vector<vtkUnstructuredGrid *> treesNodes;
114 std::vector<vtkUnstructuredGrid *> treesArcs;
115 std::vector<vtkDataSet *> treesSegmentation;
117 std::vector<std::vector<int>> treesNodeCorrMesh;
118 std::vector<ttk::ftm::MergeTree<double>> intermediateSTrees;
119 std::vector<std::vector<std::tuple<idNode, idNode, double>>> allMatching;
121 void setDataVisualization(
int numInputs) {
123 treesNodes = std::vector<vtkUnstructuredGrid *>(numInputs);
124 treesArcs = std::vector<vtkUnstructuredGrid *>(numInputs);
125 treesSegmentation = std::vector<vtkDataSet *>(numInputs);
128 void resetDataVisualization() {
129 setDataVisualization(0);
130 treesNodeCorrMesh = std::vector<std::vector<int>>();
131 intermediateSTrees = std::vector<ttk::ftm::MergeTree<double>>();
133 = std::vector<std::vector<std::tuple<idNode, idNode, double>>>();
136 bool isDataVisualizationFilled() {
137 return treesNodeCorrMesh.size() != 0 and intermediateSTrees.size() != 0
138 and allMatching.size() != 0;
150 resetDataVisualization();
159 resetDataVisualization();
166 vtkSetMacro(OutputTrees,
bool);
167 vtkGetMacro(OutputTrees,
bool);
169 vtkSetMacro(PlanarLayout,
bool);
170 vtkGetMacro(PlanarLayout,
bool);
172 vtkSetMacro(BranchDecompositionPlanarLayout,
bool);
173 vtkGetMacro(BranchDecompositionPlanarLayout,
bool);
175 vtkSetMacro(PathPlanarLayout,
bool);
176 vtkGetMacro(PathPlanarLayout,
bool);
178 vtkSetMacro(BranchSpacing,
double);
179 vtkGetMacro(BranchSpacing,
double);
181 vtkSetMacro(RescaleTreesIndividually,
bool);
182 vtkGetMacro(RescaleTreesIndividually,
bool);
184 vtkSetMacro(DimensionSpacing,
double);
185 vtkGetMacro(DimensionSpacing,
double);
187 vtkSetMacro(DimensionToShift,
int);
188 vtkGetMacro(DimensionToShift,
int);
190 vtkSetMacro(ImportantPairs,
double);
191 vtkGetMacro(ImportantPairs,
double);
193 vtkSetMacro(MaximumImportantPairs,
int);
194 vtkGetMacro(MaximumImportantPairs,
int);
196 vtkSetMacro(MinimumImportantPairs,
int);
197 vtkGetMacro(MinimumImportantPairs,
int);
199 vtkSetMacro(ImportantPairsSpacing,
double);
200 vtkGetMacro(ImportantPairsSpacing,
double);
202 vtkSetMacro(NonImportantPairsSpacing,
double);
203 vtkGetMacro(NonImportantPairsSpacing,
double);
205 vtkSetMacro(NonImportantPairsProximity,
double);
206 vtkGetMacro(NonImportantPairsProximity,
double);
208 vtkSetMacro(ExcludeImportantPairsLower,
const std::string &);
209 vtkGetMacro(ExcludeImportantPairsLower, std::string);
211 vtkSetMacro(ExcludeImportantPairsHigher,
const std::string &);
212 vtkGetMacro(ExcludeImportantPairsHigher, std::string);
246 vtkInformationVector **inputVector,
247 vtkInformationVector *outputVector)
override;
249 template <
class dataType>
250 int run(vtkInformationVector *outputVector,
252 std::vector<std::tuple<double, int, int, int, int>> &coefs,
253 std::vector<bool> &interpolatedTrees);
255 template <
class dataType>
257 std::vector<std::tuple<double, int, int, int, int>> &coefs);
259 template <
class dataType>
260 int runOutput(vtkInformationVector *outputVector,
262 std::vector<std::tuple<double, int, int, int, int>> &coefs,
263 std::vector<bool> &interpolatedTrees);