Merge topic 'debug/ctwarp3d'

7a14ea0ef Use Float64 instead of FloatDefault in TreeCompiler
96424c833 Fix bad ordering of args for CountLinkComponentsIn2DSlice in IsNecessary

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kenneth Moreland <kmorel@sandia.gov>
Merge-request: !2414
This commit is contained in:
Gunther Weber 2021-02-22 02:57:34 +00:00 committed by Kitware Robot
commit 561db99b30
2 changed files with 5 additions and 5 deletions

@ -234,13 +234,13 @@ public:
VTKM_ASSERT(pos[0] != 0 && pos[0] != this->MeshStructure.MeshSize[0]);
VTKM_ASSERT(pos[1] != 0 && pos[1] != this->MeshStructure.MeshSize[1]);
return CountLinkComponentsIn2DSlice(meshIndex,
vtkm::Id2(this->MeshStructure.MeshSize[0], 1)) != 2;
vtkm::Id2(1, this->MeshStructure.MeshSize[0])) != 2;
}
else if (pos[1] == 0 || pos[1] == this->MeshStructure.MeshSize[1] - 1)
{ // On [1]-perpendicular face
VTKM_ASSERT(pos[0] != 0 && pos[0] != this->MeshStructure.MeshSize[0]);
VTKM_ASSERT(pos[2] != 0 && pos[2] != this->MeshStructure.MeshSize[2]);
return CountLinkComponentsIn2DSlice(meshIndex, vtkm::Id2(nPerSlice, 1)) != 2;
return CountLinkComponentsIn2DSlice(meshIndex, vtkm::Id2(1, nPerSlice)) != 2;
}
else
{ // On [0]-perpendicular face
@ -248,7 +248,7 @@ public:
VTKM_ASSERT(pos[1] != 0 && pos[1] != this->MeshStructure.MeshSize[1]);
VTKM_ASSERT(pos[2] != 0 && pos[2] != this->MeshStructure.MeshSize[2]);
return CountLinkComponentsIn2DSlice(
meshIndex, vtkm::Id2(this->MeshStructure.MeshSize[0], nPerSlice)) != 2;
meshIndex, vtkm::Id2(nPerSlice, this->MeshStructure.MeshSize[0])) != 2;
}
}
}

@ -69,7 +69,7 @@ namespace contourtree_distributed
{
// Possibly change the following when comapring to PPP prototype
constexpr int PRINT_WIDTH = 12;
using dataType = vtkm::FloatDefault;
using dataType = vtkm::Float64;
using indexType = vtkm::Id;
// small class for storing the contour arcs
@ -224,7 +224,7 @@ inline void TreeCompiler::AddHierarchicalTree(const vtkm::cont::DataSet& addedTr
{ // TreeCompiler::AddHierarchicalTree()
// Copy relevant tree content to STL arrays
vtkm::cont::UnknownArrayHandle dataValues_array = addedTree.GetField("DataValues").GetData();
std::vector<vtkm::FloatDefault> dataValues(dataValues_array.GetNumberOfValues());
std::vector<vtkm::Float64> dataValues(dataValues_array.GetNumberOfValues());
auto dataValues_handle = vtkm::cont::make_ArrayHandle(dataValues, vtkm::CopyFlag::Off);
vtkm::cont::ArrayCopy(dataValues_array, dataValues_handle);
dataValues_handle.SyncControlArray();