VTK-m  2.0
TreeCompiler.h
Go to the documentation of this file.
1 //============================================================================
2 // Copyright (c) Kitware, Inc.
3 // All rights reserved.
4 // See LICENSE.txt for details.
5 //
6 // This software is distributed WITHOUT ANY WARRANTY; without even
7 // the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
8 // PURPOSE. See the above copyright notice for more information.
9 //============================================================================
10 // Copyright (c) 2018, The Regents of the University of California, through
11 // Lawrence Berkeley National Laboratory (subject to receipt of any required approvals
12 // from the U.S. Dept. of Energy). All rights reserved.
13 //
14 // Redistribution and use in source and binary forms, with or without modification,
15 // are permitted provided that the following conditions are met:
16 //
17 // (1) Redistributions of source code must retain the above copyright notice, this
18 // list of conditions and the following disclaimer.
19 //
20 // (2) Redistributions in binary form must reproduce the above copyright notice,
21 // this list of conditions and the following disclaimer in the documentation
22 // and/or other materials provided with the distribution.
23 //
24 // (3) Neither the name of the University of California, Lawrence Berkeley National
25 // Laboratory, U.S. Dept. of Energy nor the names of its contributors may be
26 // used to endorse or promote products derived from this software without
27 // specific prior written permission.
28 //
29 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
30 // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
31 // WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
32 // IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
33 // INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
34 // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
35 // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
36 // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
37 // OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
38 // OF THE POSSIBILITY OF SUCH DAMAGE.
39 //
40 //=============================================================================
41 //
42 // This code is an extension of the algorithm presented in the paper:
43 // Parallel Peak Pruning for Scalable SMP Contour Tree Computation.
44 // Hamish Carr, Gunther Weber, Christopher Sewell, and James Ahrens.
45 // Proceedings of the IEEE Symposium on Large Data Analysis and Visualization
46 // (LDAV), October 2016, Baltimore, Maryland.
47 //
48 // The PPP2 algorithm and software were jointly developed by
49 // Hamish Carr (University of Leeds), Gunther H. Weber (LBNL), and
50 // Oliver Ruebel (LBNL)
51 //==============================================================================
52 
53 
54 #ifndef _TREECOMPILER_H_
55 #define _TREECOMPILER_H_
56 
57 #include <iomanip>
58 #include <iostream>
59 #include <vtkm/Types.h>
60 #include <vtkm/cont/ArrayCopy.h>
61 #include <vtkm/cont/DataSet.h>
63 
64 namespace vtkm
65 {
66 namespace worklet
67 {
68 namespace contourtree_distributed
69 {
70 // Possibly change the following when comapring to PPP prototype
71 constexpr int PRINT_WIDTH = 12;
74 
75 // small class for storing the contour arcs
76 class Edge
77 { // Edge
78 public:
80 
81  // constructor - defaults to -1
82  Edge(vtkm::Id Low = -1, vtkm::Id High = -1)
83  : low(Low)
84  , high(High)
85  {
86  }
87 }; // Edge
88 
89 // comparison operator <
90 inline bool operator<(const Edge& LHS, const Edge& RHS)
91 { // operator <
92 #if 0
93  if (LHS.low < RHS.low) return true;
94  if (LHS.low > RHS.low) return false;
95  if (LHS.high < RHS.high) return true;
96  if (LHS.high > RHS.high) return false;
97 #endif
98  if (std::min(LHS.low, LHS.high) < std::min(RHS.low, RHS.high))
99  return true;
100  else if (std::min(LHS.low, LHS.high) > std::min(RHS.low, RHS.high))
101  return false;
102  if (std::max(LHS.low, LHS.high) < std::max(RHS.low, RHS.high))
103  return true;
104  else if (std::max(LHS.low, LHS.high) > std::max(RHS.low, RHS.high))
105  return false;
106  return false;
107 } // operator <
108 
109 // comparison operator ==
110 inline bool operator==(const Edge& LHS, const Edge& RHS)
111 { // operator ==
112  return (LHS.low == RHS.low && LHS.high == RHS.high) ||
113  (LHS.low == RHS.high && LHS.high == RHS.low);
114 } // operator ==
115 
116 // a helper class which stores a single supernode inserted onto a superarc
118 { // class SupernodeOnSuperarc
119 public:
120  // the global ID of the supernode
122  // the data value stored at the supernode
124 
125  // the low and high ends of the superarc it is on (may be itself)
127 
128  // constructor
133  : globalID(GlobalID)
134  , dataValue(DataValue)
135  , lowEnd(LowEnd)
136  , highEnd(HighEnd)
137  { // constructor
138  } // constructor
139 }; // class SupernodeOnSuperarc
140 
141 // overloaded comparison operator
142 // primary sort is by superarc (low, high),
143 // then secondary sort on datavalue
144 // tertiary on globalID to implement simulated simplicity
145 inline bool operator<(const SupernodeOnSuperarc& left, const SupernodeOnSuperarc& right)
146 { // < operator
147  // simple lexicographic sort
148  if (left.lowEnd < right.lowEnd)
149  return true;
150  if (left.lowEnd > right.lowEnd)
151  return false;
152  if (left.highEnd < right.highEnd)
153  return true;
154  if (left.highEnd > right.highEnd)
155  return false;
156  if (left.dataValue < right.dataValue)
157  return true;
158  if (left.dataValue > right.dataValue)
159  return false;
160  if (left.globalID < right.globalID)
161  return true;
162  if (left.globalID > right.globalID)
163  return false;
164 
165  // fall-through (shouldn't happen, but)
166  // if they're the same, it's false
167  return false;
168 } // < operator
169 
170 // stream output
171 std::ostream& operator<<(std::ostream& outStream, SupernodeOnSuperarc& node);
172 
173 // stream input
174 std::istream& operator>>(std::istream& inStream, SupernodeOnSuperarc& node);
175 
176 // the class that compiles the contour tree
178 { // class TreeCompiler
179 public:
180  // we want a vector of supernodes on superarcs
181  std::vector<SupernodeOnSuperarc> supernodes;
182 
183  // and a vector of Edges (the output)
184  std::vector<Edge> superarcs;
185 
186  // routine to add a known hierarchical tree to it
187  // note that this DOES NOT finalise - we don't want too many sorts
188  void AddHierarchicalTree(const vtkm::cont::DataSet& addedTree);
189 
190  // routine to compute the actual superarcs
191  void ComputeSuperarcs();
192 
193  // routine to print a superarcs array in our format
194  static void PrintSuperarcArray(const std::vector<Edge>& superarc_array);
195 
196  // routine to print the superarcs
197  void PrintSuperarcs(bool) const;
198 
199  // routine to write out binary file
200  void WriteBinary(FILE* outFile) const;
201 
202  // routine to read in binary file & append to contents
203  void ReadBinary(FILE* inFile);
204 }; // class TreeCompiler
205 
206 // stream output
207 inline std::ostream& operator<<(std::ostream& outStream, SupernodeOnSuperarc& node)
208 { // stream output
209  outStream << node.lowEnd << " " << node.highEnd << " " << node.dataValue << " " << node.globalID
210  << std::endl;
211  return outStream;
212 } // stream output
213 
214 // stream input
215 inline std::istream& operator>>(std::istream& inStream, SupernodeOnSuperarc& node)
216 { // stream input
217  inStream >> node.lowEnd >> node.highEnd >> node.dataValue >> node.globalID;
218  return inStream;
219 } // stream input
220 
221 // routine to add a known hierarchical tree to it
222 // note that this DOES NOT finalise - we don't want too many sorts
224 { // TreeCompiler::AddHierarchicalTree()
225  // Copy relevant tree content to STL arrays
226  vtkm::cont::UnknownArrayHandle dataValues_array = addedTree.GetField("DataValues").GetData();
227  std::vector<vtkm::Float64> dataValues(dataValues_array.GetNumberOfValues());
228  auto dataValues_handle = vtkm::cont::make_ArrayHandle(dataValues, vtkm::CopyFlag::Off);
229  vtkm::cont::ArrayCopy(dataValues_array, dataValues_handle);
230  dataValues_handle.SyncControlArray();
231 
232  auto regularNodeGlobalIds_array = addedTree.GetField("RegularNodeGlobalIds").GetData();
233  std::vector<vtkm::Id> regularNodeGlobalIds(regularNodeGlobalIds_array.GetNumberOfValues());
234  auto regularNodeGlobalIds_handle =
235  vtkm::cont::make_ArrayHandle(regularNodeGlobalIds, vtkm::CopyFlag::Off);
236  vtkm::cont::ArrayCopy(regularNodeGlobalIds_array, regularNodeGlobalIds_handle);
237  regularNodeGlobalIds_handle
238  .SyncControlArray(); //Forces values to get updated if copy happened on GPU
239 
240  auto superarcs_array = addedTree.GetField("Superarcs").GetData();
241  std::vector<vtkm::Id> added_tree_superarcs(superarcs_array.GetNumberOfValues());
242  auto superarcs_handle = vtkm::cont::make_ArrayHandle(added_tree_superarcs, vtkm::CopyFlag::Off);
243  vtkm::cont::ArrayCopy(superarcs_array, superarcs_handle);
244  superarcs_handle.SyncControlArray(); //Forces values to get updated if copy happened on GPU
245 
246  auto supernodes_array = addedTree.GetField("Supernodes").GetData();
247  std::vector<vtkm::Id> added_tree_supernodes(supernodes_array.GetNumberOfValues());
248  auto supernodes_handle = vtkm::cont::make_ArrayHandle(added_tree_supernodes, vtkm::CopyFlag::Off);
249  vtkm::cont::ArrayCopy(supernodes_array, supernodes_handle);
250  supernodes_handle.SyncControlArray(); //Forces values to get updated if copy happened on GPU
251 
252  auto superparents_array = addedTree.GetField("Superparents").GetData();
253  std::vector<vtkm::Id> superparents(superparents_array.GetNumberOfValues());
254  auto superparents_handle = vtkm::cont::make_ArrayHandle(superparents, vtkm::CopyFlag::Off);
255  vtkm::cont::ArrayCopy(superparents_array, superparents_handle);
256  superparents_handle.SyncControlArray(); //Forces values to get updated if copy happened on GPU
257 
258  // loop through all of the supernodes in the hierarchical tree
259  for (indexType supernode = 0; supernode < static_cast<indexType>(added_tree_supernodes.size());
260  supernode++)
261  { // per supernode
262  // retrieve the regular ID for the supernode
263  indexType regularId = added_tree_supernodes[supernode];
264  indexType globalId = regularNodeGlobalIds[regularId];
265  dataType dataVal = dataValues[regularId];
266 
267  // retrieve the supernode at the far end
268  indexType superTo = added_tree_superarcs[supernode];
269 
270  // now test - if it is NO_SUCH_ELEMENT, there are two possibilities
272  { // no Superto
273 
274  // retrieve the superparent
275  indexType superparent = superparents[regularId];
276 
277 
278  // the root node will have itself as its superparent
279  if (superparent == supernode)
280  continue;
281  else
282  { // not own superparent - an attachment point
283  // retrieve the superparent's from & to
284  indexType regularFrom = added_tree_supernodes[superparent];
285  indexType globalFrom = regularNodeGlobalIds[regularFrom];
286  indexType superParentTo = added_tree_superarcs[superparent];
287  indexType regularTo =
288  added_tree_supernodes[vtkm::worklet::contourtree_augmented::MaskedIndex(superParentTo)];
289  indexType globalTo = regularNodeGlobalIds[regularTo];
290 
291  // test the superTo to see whether we ascend or descend
292  // note that we will never have NO_SUCH_ELEMENT here
294  { // ascending
295  this->supernodes.push_back(SupernodeOnSuperarc(globalId, dataVal, globalFrom, globalTo));
296  } // ascending
297  else
298  { // descending
299  this->supernodes.push_back(SupernodeOnSuperarc(globalId, dataVal, globalTo, globalFrom));
300  } // descending
301  } // not own superparent - an attachment point
302  } // no Superto
303  else
304  { // there is a valid superarc
305  // retrieve the "to" and convert to global
307  indexType regularTo = added_tree_supernodes[maskedTo];
308  indexType globalTo = regularNodeGlobalIds[regularTo];
309  dataType dataTo = dataValues[regularTo];
310 
311  // test the superTo to see whether we ascend or descend
312  // note that we will never have NO_SUCH_ELEMENT here
313  // we add both ends
315  { // ascending
316  this->supernodes.push_back(SupernodeOnSuperarc(globalId, dataVal, globalId, globalTo));
317  this->supernodes.push_back(SupernodeOnSuperarc(globalTo, dataTo, globalId, globalTo));
318  } // ascending
319  else
320  { // descending
321  this->supernodes.push_back(SupernodeOnSuperarc(globalId, dataVal, globalTo, globalId));
322  this->supernodes.push_back(SupernodeOnSuperarc(globalTo, dataTo, globalTo, globalId));
323  } // descending
324  } // there is a valid superarc
325  } // per supernode
326 
327 } // TreeCompiler::AddHierarchicalTree()
328 
329 // routine to compute the actual superarcs
331 { // TreeCompiler::ComputeSuperarcs()
332  // first we sort the vector
333  std::sort(supernodes.begin(), supernodes.end());
334 
335  // we could do a unique test here, but it's easier just to suppress it inside the loop
336 
337  // now we loop through it: note the -1
338  // this is because we know a priori that the last one is the last supernode on a superarc
339  // and would fail the test inside the loop. By putting it in the loop test, we avoid having
340  // to have an explicit if statement inside the loop
341  for (indexType supernode = 0; supernode < static_cast<vtkm::Id>(supernodes.size() - 1);
342  supernode++)
343  { // loop through supernodes
344  // this is actually painfully simple: if the (lowEnd, highEnd) don't match the next one,
345  // then we're at the end of the group and do nothing. Otherwise, we link to the next one
346  if ((supernodes[supernode].lowEnd != supernodes[supernode + 1].lowEnd) ||
347  (supernodes[supernode].highEnd != supernodes[supernode + 1].highEnd))
348  continue;
349 
350  // if the supernode matches, then we have a repeat, and can suppress
351  if (supernodes[supernode].globalID == supernodes[supernode + 1].globalID)
352  continue;
353 
354  // otherwise, add a superarc to the list
355  superarcs.push_back(Edge(supernodes[supernode].globalID, supernodes[supernode + 1].globalID));
356  } // loop through supernodes
357 
358  // now sort them
359  std::sort(superarcs.begin(), superarcs.end());
360 } // TreeCompiler::ComputeSuperarcs()
361 
362 // routine to print the superarcs
363 inline void TreeCompiler::PrintSuperarcArray(const std::vector<Edge>& superarc_array)
364 { // TreeCompiler::PrintSuperarcArray()
365  for (indexType superarc = 0; superarc < static_cast<indexType>(superarc_array.size()); superarc++)
366  { // per superarc
367  if (superarc_array[superarc].low < superarc_array[superarc].high)
368  { // order by ID not value
369  std::cout << std::setw(PRINT_WIDTH) << superarc_array[superarc].low << " ";
370  std::cout << std::setw(PRINT_WIDTH) << superarc_array[superarc].high << std::endl;
371  } // order by ID not value
372  else
373  { // order by ID not value
374  std::cout << std::setw(PRINT_WIDTH) << superarc_array[superarc].high << " ";
375  std::cout << std::setw(PRINT_WIDTH) << superarc_array[superarc].low << std::endl;
376  } // order by ID not value
377 
378  } // per superarc
379 
380 } // TreeCompiler::PrintSuperarcArray()
381 
382 inline void TreeCompiler::PrintSuperarcs(bool printHeader = false) const
383 {
384  if (printHeader)
385  {
386  std::cout << "============" << std::endl;
387  std::cout << "Contour Tree" << std::endl;
388  }
389 
391 }
392 
393 // routine to write out binary file
394 inline void TreeCompiler::WriteBinary(FILE* outFile) const
395 { // WriteBinary()
396  // do a bulk write of the entire contents
397  // no error checking, no type checking, no nothing
398  fwrite(&(supernodes[0]), sizeof(SupernodeOnSuperarc), supernodes.size(), outFile);
399 } // WriteBinary()
400 
401 // routine to read in binary file and append
402 inline void TreeCompiler::ReadBinary(FILE* inFile)
403 { // ReadBinary()
404  // use fseek to jump to the end
405  fseek(inFile, 0, SEEK_END);
406 
407  // use fTell to retrieve the size of the file
408  std::size_t nBytes = ftell(inFile);
409  // now rewind
410  rewind(inFile);
411 
412  // compute how many elements are to be read
413  std::size_t nSupernodes = nBytes / sizeof(SupernodeOnSuperarc);
414 
415  // retrieve the current size
416  std::size_t currentSize = supernodes.size();
417 
418  // resize to add the right number
419  supernodes.resize(currentSize + nSupernodes);
420 
421  // now read directly into the right chunk
422  std::size_t nSupernodesRead =
423  fread(&(supernodes[currentSize]), sizeof(SupernodeOnSuperarc), nSupernodes, inFile);
424 
425  if (nSupernodesRead != nSupernodes)
426  {
428  "Error: Expected to read " << nSupernodes << " supernodes but could read only "
429  << nSupernodesRead << ". Output will be incorrect!"
430  << std::endl);
431  }
432 } // ReadBinary()
433 
434 // stream output - just dumps the supernodeonsuperarcs
435 inline std::ostream& operator<<(std::ostream& outStream, TreeCompiler& tree)
436 { // stream output
437  for (indexType supernode = 0; supernode < static_cast<indexType>(tree.supernodes.size());
438  supernode++)
439  outStream << tree.supernodes[supernode];
440  return outStream;
441 } // stream output
442 
443 // stream input - reads in the supernodeonsuperarcs & appends them
444 inline std::istream& operator>>(std::istream& inStream, TreeCompiler& tree)
445 { // stream input
446  while (!inStream.eof())
447  {
448  SupernodeOnSuperarc tempNode;
449  inStream >> tempNode;
450  tree.supernodes.push_back(tempNode);
451  }
452  // we will overshoot, so subtract one
453  tree.supernodes.resize(tree.supernodes.size() - 1);
454  return inStream;
455 } // stream input
456 
457 } // namespace contourtree_distributed
458 } // namespace worklet
459 } // namespace vtkm
460 
461 #endif
vtkm::worklet::contourtree_distributed::Edge
Definition: TreeCompiler.h:76
vtkm::worklet::contourtree_distributed::dataType
vtkm::Float64 dataType
Definition: TreeCompiler.h:72
vtkm::cont::make_ArrayHandle
VTKM_CONT vtkm::cont::ArrayHandleBasic< T > make_ArrayHandle(const T *array, vtkm::Id numberOfValues, vtkm::CopyFlag copy)
A convenience function for creating an ArrayHandle from a standard C array.
Definition: ArrayHandleBasic.h:217
vtkm::worklet::contourtree_augmented::IsAscending
VTKM_EXEC_CONT bool IsAscending(vtkm::Id flaggedIndex)
Definition: filter/scalar_topology/worklet/contourtree_augmented/Types.h:121
vtkm::worklet::contourtree_distributed::SupernodeOnSuperarc
Definition: TreeCompiler.h:117
vtkm
Groups connected points that have the same field value.
Definition: Atomic.h:19
Types.h
vtkm::worklet::contourtree_distributed::SupernodeOnSuperarc::dataValue
dataType dataValue
Definition: TreeCompiler.h:123
vtkm::worklet::contourtree_distributed::SupernodeOnSuperarc::highEnd
indexType highEnd
Definition: TreeCompiler.h:126
vtkm::worklet::contourtree_distributed::TreeCompiler::AddHierarchicalTree
void AddHierarchicalTree(const vtkm::cont::DataSet &addedTree)
Definition: TreeCompiler.h:223
vtkm::worklet::contourtree_distributed::indexType
vtkm::Id indexType
Definition: TreeCompiler.h:73
vtkm::cont::UnknownArrayHandle
An ArrayHandle of an unknown value type and storage.
Definition: UnknownArrayHandle.h:406
vtkm::worklet::contourtree_distributed::TreeCompiler::superarcs
std::vector< Edge > superarcs
Definition: TreeCompiler.h:184
vtkm::cont::DataSet
Definition: DataSet.h:34
vtkm::worklet::contourtree_distributed::TreeCompiler
Definition: TreeCompiler.h:177
vtkm::worklet::contourtree_distributed::TreeCompiler::PrintSuperarcs
void PrintSuperarcs(bool) const
Definition: TreeCompiler.h:382
vtkm::worklet::contourtree_augmented::MaskedIndex
VTKM_EXEC_CONT vtkm::Id MaskedIndex(vtkm::Id flaggedIndex)
Definition: filter/scalar_topology/worklet/contourtree_augmented/Types.h:127
vtkm::worklet::contourtree_distributed::operator<
bool operator<(const Edge &LHS, const Edge &RHS)
Definition: TreeCompiler.h:90
vtkm::Id
vtkm::Int32 Id
Represents an ID (index into arrays).
Definition: Types.h:191
ArrayCopy.h
vtkm::cont::Field::GetData
const vtkm::cont::UnknownArrayHandle & GetData() const
vtkm::worklet::contourtree_distributed::Edge::low
indexType low
Definition: TreeCompiler.h:79
vtkm::worklet::contourtree_distributed::TreeCompiler::PrintSuperarcArray
static void PrintSuperarcArray(const std::vector< Edge > &superarc_array)
Definition: TreeCompiler.h:363
vtkm::worklet::contourtree_augmented::NoSuchElement
VTKM_EXEC_CONT bool NoSuchElement(vtkm::Id flaggedIndex)
Definition: filter/scalar_topology/worklet/contourtree_augmented/Types.h:97
vtkm::worklet::contourtree_distributed::SupernodeOnSuperarc::globalID
indexType globalID
Definition: TreeCompiler.h:121
vtkm::cont::ArrayCopy
void ArrayCopy(const SourceArrayType &source, DestArrayType &destination)
Does a deep copy from one array to another array.
Definition: ArrayCopy.h:142
Types.h
vtkm::worklet::contourtree_distributed::Edge::Edge
Edge(vtkm::Id Low=-1, vtkm::Id High=-1)
Definition: TreeCompiler.h:82
vtkm::cont::LogLevel::Error
@ Error
Important but non-fatal errors, such as device fail-over.
VTKM_LOG_S
#define VTKM_LOG_S(level,...)
Writes a message using stream syntax to the indicated log level.
Definition: Logging.h:261
vtkm::CopyFlag::Off
@ Off
vtkm::worklet::contourtree_distributed::Edge::high
indexType high
Definition: TreeCompiler.h:79
vtkm::worklet::contourtree_distributed::TreeCompiler::WriteBinary
void WriteBinary(FILE *outFile) const
Definition: TreeCompiler.h:394
vtkm::worklet::contourtree_distributed::operator==
bool operator==(const Edge &LHS, const Edge &RHS)
Definition: TreeCompiler.h:110
vtkm::worklet::contourtree_distributed::SupernodeOnSuperarc::lowEnd
indexType lowEnd
Definition: TreeCompiler.h:126
vtkm::Float64
double Float64
Definition: Types.h:155
vtkm::worklet::contourtree_distributed::PRINT_WIDTH
constexpr int PRINT_WIDTH
Definition: TreeCompiler.h:71
vtkm::cont::UnknownArrayHandle::GetNumberOfValues
VTKM_CONT vtkm::Id GetNumberOfValues() const
Returns the number of values in the array.
vtkm::cont::DataSet::GetField
const VTKM_CONT vtkm::cont::Field & GetField(vtkm::Id index) const
Retrieves a field by index.
Definition: DataSet.h:75
vtkm::worklet::contourtree_distributed::SupernodeOnSuperarc::SupernodeOnSuperarc
SupernodeOnSuperarc(indexType GlobalID=vtkm::worklet::contourtree_augmented::NO_SUCH_ELEMENT, dataType DataValue=vtkm::worklet::contourtree_augmented::NO_SUCH_ELEMENT, indexType LowEnd=vtkm::worklet::contourtree_augmented::NO_SUCH_ELEMENT, indexType HighEnd=vtkm::worklet::contourtree_augmented::NO_SUCH_ELEMENT)
Definition: TreeCompiler.h:129
vtkm::worklet::contourtree_distributed::TreeCompiler::supernodes
std::vector< SupernodeOnSuperarc > supernodes
Definition: TreeCompiler.h:181
vtkm::worklet::contourtree_distributed::TreeCompiler::ReadBinary
void ReadBinary(FILE *inFile)
Definition: TreeCompiler.h:402
vtkm::worklet::contourtree_distributed::operator<<
std::ostream & operator<<(std::ostream &outStream, SupernodeOnSuperarc &node)
Definition: TreeCompiler.h:207
vtkm::worklet::contourtree_distributed::operator>>
std::istream & operator>>(std::istream &inStream, SupernodeOnSuperarc &node)
Definition: TreeCompiler.h:215
vtkm::worklet::contourtree_augmented::NO_SUCH_ELEMENT
constexpr vtkm::Id NO_SUCH_ELEMENT
Definition: filter/scalar_topology/worklet/contourtree_augmented/Types.h:73
DataSet.h
vtkm::worklet::contourtree_distributed::TreeCompiler::ComputeSuperarcs
void ComputeSuperarcs()
Definition: TreeCompiler.h:330