VTK-m  2.0
Public Member Functions | Public Attributes | Private Member Functions | List of all members
vtkm::worklet::ContourTreeAugmented Class Reference

Compute the contour tree for 2d and 3d uniform grids and arbitrary topology graphs. More...

#include <ContourTreeUniformAugmented.h>

Public Member Functions

template<typename FieldType , typename StorageType , typename MeshType , typename MeshBoundaryMeshExecType >
void Run (const vtkm::cont::ArrayHandle< FieldType, StorageType > fieldArray, MeshType &mesh, contourtree_augmented::ContourTree &contourTree, contourtree_augmented::IdArrayType &sortOrder, vtkm::Id &nIterations, unsigned int computeRegularStructure, const MeshBoundaryMeshExecType &meshBoundary)
 
template<typename FieldType , typename StorageType >
void Run (const vtkm::cont::ArrayHandle< FieldType, StorageType > fieldArray, contourtree_augmented::ContourTree &contourTree, contourtree_augmented::IdArrayType &sortOrder, vtkm::Id &nIterations, const vtkm::Id3 meshSize, bool useMarchingCubes=false, unsigned int computeRegularStructure=1)
 

Public Attributes

vtkm::cont::LogLevel TimingsLogLevel = vtkm::cont::LogLevel::Perf
 
std::string TimingsLogString
 Remember the results from our time-keeping so we can customize our logging. More...
 

Private Member Functions

template<typename FieldType , typename StorageType , typename MeshClass , typename MeshBoundaryClass >
void RunContourTree (const vtkm::cont::ArrayHandle< FieldType, StorageType > fieldArray, contourtree_augmented::ContourTree &contourTree, contourtree_augmented::IdArrayType &sortOrder, vtkm::Id &nIterations, MeshClass &mesh, unsigned int computeRegularStructure, const MeshBoundaryClass &meshBoundary)
 

Detailed Description

Compute the contour tree for 2d and 3d uniform grids and arbitrary topology graphs.

Member Function Documentation

◆ Run() [1/2]

template<typename FieldType , typename StorageType >
void vtkm::worklet::ContourTreeAugmented::Run ( const vtkm::cont::ArrayHandle< FieldType, StorageType >  fieldArray,
contourtree_augmented::ContourTree contourTree,
contourtree_augmented::IdArrayType sortOrder,
vtkm::Id nIterations,
const vtkm::Id3  meshSize,
bool  useMarchingCubes = false,
unsigned int  computeRegularStructure = 1 
)
inline

Run the contour tree analysis. This helper function is used to allow one to run the contour tree in a consistent fashion independent of whether the data is 2D, 3D, or 3D_MC. This function initalizes the approbritate mesh class from the contourtree_augmented worklet and constructs ths mesh boundary exectuion object to be used. It the subsequently calls RunContourTree method to compute the actual contour tree.

fieldArray : Needed only as a pass-through value but not used in this case mesh : The ContourTreeMesh for which the contour tree should be computed contourTree : The output contour tree to be computed (output) sortOrder : The sort order for the mesh vertices (output) nIterations : The number of iterations used to compute the contour tree (output) nRows : Number of rows (i.e, x values) in the input mesh nCols : Number of columns (i.e, y values) in the input mesh nSlices : Number of slicex (i.e, z values) in the input mesh. Default is 1 to avoid having to set the nSlices for 2D input meshes useMarchingCubes : Boolean indicating whether marching cubes (true) or freudenthal (false) connectivity should be used. Valid only for 3D input data. Default is false. computeRegularStructure : 0=Off, 1=full augmentation with all vertices 2=boundary augmentation using meshBoundary.

◆ Run() [2/2]

template<typename FieldType , typename StorageType , typename MeshType , typename MeshBoundaryMeshExecType >
void vtkm::worklet::ContourTreeAugmented::Run ( const vtkm::cont::ArrayHandle< FieldType, StorageType >  fieldArray,
MeshType &  mesh,
contourtree_augmented::ContourTree contourTree,
contourtree_augmented::IdArrayType sortOrder,
vtkm::Id nIterations,
unsigned int  computeRegularStructure,
const MeshBoundaryMeshExecType &  meshBoundary 
)
inline

Run the contour tree to merge an existing set of contour trees

fieldArray : Needed only as a pass-through value but not used in this case mesh : The ContourTreeMesh for which the contour tree should be computed contourTree : The output contour tree to be computed (output) sortOrder : The sort order for the mesh vertices (output) nIterations : The number of iterations used to compute the contour tree (output) computeRegularStructure : 0=Off, 1=full augmentation with all vertices 2=boundary augmentation using meshBoundary meshBoundary : This parameter is generated by calling mesh.GetMeshBoundaryExecutionObject For regular 2D/3D meshes this required no extra parameters, however, for a ContourTreeMesh additional information about the block must be given. Rather than generating the MeshBoundary descriptor here, we therefore, require it as an input. The MeshBoundary is used to augment the contour tree with the mesh boundary vertices. It is needed only if we want to augement by the mesh boundary and computeRegularStructure is False (i.e., if we compute the full regular strucuture this is not needed because all vertices (including the boundary) will be addded to the tree anyways.

◆ RunContourTree()

template<typename FieldType , typename StorageType , typename MeshClass , typename MeshBoundaryClass >
void vtkm::worklet::ContourTreeAugmented::RunContourTree ( const vtkm::cont::ArrayHandle< FieldType, StorageType >  fieldArray,
contourtree_augmented::ContourTree contourTree,
contourtree_augmented::IdArrayType sortOrder,
vtkm::Id nIterations,
MeshClass &  mesh,
unsigned int  computeRegularStructure,
const MeshBoundaryClass &  meshBoundary 
)
inlineprivate

Run the contour tree for the given mesh. This function implements the main steps for computing the contour tree after the mesh has been constructed using the approbrite contour tree mesh class.

fieldArray : The values of the mesh contourTree : The output contour tree to be computed (output) sortOrder : The sort order for the mesh vertices (output) nIterations : The number of iterations used to compute the contour tree (output) mesh : The specific mesh (see vtkm/worklet/contourtree_augmented/mesh_dem_meshtypes computeRegularStructure : 0=Off, 1=full augmentation with all vertices 2=boundary augmentation using meshBoundary meshBoundary : This parameter is generated by calling mesh.GetMeshBoundaryExecutionObject For regular 2D/3D meshes this required no extra parameters, however, for a ContourTreeMesh additional information about the block must be given. Rather than generating the MeshBoundary descriptor here, we therefore, require it as an input. The MeshBoundary is used to augment the contour tree with the mesh boundary vertices. It is needed only if we want to augement by the mesh boundary and computeRegularStructure is False (i.e., if we compute the full regular strucuture this is not needed because all vertices (including the boundary) will be addded to the tree anyways.

Member Data Documentation

◆ TimingsLogLevel

vtkm::cont::LogLevel vtkm::worklet::ContourTreeAugmented::TimingsLogLevel = vtkm::cont::LogLevel::Perf

Log level to be used for outputting timing information. Default is vtkm::cont::LogLevel::Perf Use vtkm::cont::LogLevel::Off to disable outputing the results via vtkm logging here. The results are saved in the TimingsLogString variable so we can use it to do our own logging

◆ TimingsLogString

std::string vtkm::worklet::ContourTreeAugmented::TimingsLogString

Remember the results from our time-keeping so we can customize our logging.


The documentation for this class was generated from the following file: