mirror of
https://gitlab.kitware.com/vtk/vtk-m
synced 2024-09-08 13:23:51 +00:00
Merge topic 'add_get_block_to_boundsmap'
b43763429 Kick the dashboards..... f3279b0f5 Merge branch 'add_get_block_to_boundsmap' of https://gitlab.kitware.com/dpugmire/vtk-m into add_get_block_to_boundsmap 1ce2922d1 Remove warning. Add BoundsMap methods. b9a684fda Merge branch 'master' of https://gitlab.kitware.com/vtk/vtk-m into add_get_block_to_boundsmap a4b4bf656 Merge branch 'master' of https://gitlab.kitware.com/vtk/vtk-m 086f99e54 Merge branch 'master' of https://gitlab.kitware.com/vtk/vtk-m into add_get_block_to_boundsmap 166f5d405 Kick the dashboards..... 5fba6382b Kick the dashboards.......... ... Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3041
This commit is contained in:
commit
8651d9f284
@ -137,8 +137,8 @@ protected:
|
||||
if (!this->UseAsynchronousCommunication)
|
||||
{
|
||||
VTKM_LOG_S(vtkm::cont::LogLevel::Info,
|
||||
"Synchronous communication not supported for AdvectAlgorithmThreaded. Forcing "
|
||||
"asynchronous communication.");
|
||||
"Synchronous communication not supported for AdvectAlgorithmThreaded."
|
||||
"Forcing asynchronous communication.");
|
||||
}
|
||||
|
||||
bool useAsync = true;
|
||||
|
@ -61,6 +61,15 @@ public:
|
||||
this->Init(pds.GetPartitions(), blockIds);
|
||||
}
|
||||
|
||||
vtkm::Bounds GetGlobalBounds() const { return this->GlobalBounds; }
|
||||
|
||||
vtkm::Bounds GetBlockBounds(vtkm::Id idx) const
|
||||
{
|
||||
VTKM_ASSERT(idx >= 0 && static_cast<std::size_t>(idx) < this->BlockBounds.size());
|
||||
|
||||
return this->BlockBounds[static_cast<std::size_t>(idx)];
|
||||
}
|
||||
|
||||
vtkm::Id GetLocalBlockId(vtkm::Id idx) const
|
||||
{
|
||||
VTKM_ASSERT(idx >= 0 && idx < this->LocalNumBlocks);
|
||||
@ -138,7 +147,7 @@ private:
|
||||
|
||||
//note: there might be duplicates...
|
||||
vtkm::Id globalNumBlocks =
|
||||
std::accumulate(globalBlockCounts.begin(), globalBlockCounts.end(), 0);
|
||||
std::accumulate(globalBlockCounts.begin(), globalBlockCounts.end(), vtkm::Id{ 0 });
|
||||
|
||||
//3. given the counts per rank, calc offset for this rank.
|
||||
vtkm::Id offset = 0;
|
||||
|
@ -74,15 +74,16 @@ public:
|
||||
|
||||
void Validate(vtkm::Id num)
|
||||
{
|
||||
#ifndef NDEBUG
|
||||
//Make sure we didn't miss anything. Every particle goes into a single bucket.
|
||||
VTKM_ASSERT(static_cast<std::size_t>(num) ==
|
||||
(this->InBounds.Particles.size() + this->OutOfBounds.Particles.size() +
|
||||
this->TermIdx.size()));
|
||||
VTKM_ASSERT(this->InBounds.Particles.size() == this->InBounds.BlockIDs.size());
|
||||
VTKM_ASSERT(this->OutOfBounds.Particles.size() == this->OutOfBounds.BlockIDs.size());
|
||||
VTKM_ASSERT(this->TermIdx.size() == this->TermID.size());
|
||||
#endif
|
||||
if ((static_cast<std::size_t>(num) !=
|
||||
(this->InBounds.Particles.size() + this->OutOfBounds.Particles.size() +
|
||||
this->TermIdx.size())) ||
|
||||
(this->InBounds.Particles.size() != this->InBounds.BlockIDs.size()) ||
|
||||
(this->OutOfBounds.Particles.size() != this->OutOfBounds.BlockIDs.size()) ||
|
||||
(this->TermIdx.size() != this->TermID.size()))
|
||||
{
|
||||
throw vtkm::cont::ErrorFilterExecution("Particle count mismatch after classification");
|
||||
}
|
||||
}
|
||||
|
||||
void AddTerminated(vtkm::Id idx, vtkm::Id pID)
|
||||
|
@ -115,10 +115,10 @@ void SetFilter(FilterType& filter,
|
||||
filter.SetSeeds(seedArray);
|
||||
filter.SetActiveField(fieldName);
|
||||
filter.SetUseThreadedAlgorithm(useThreaded);
|
||||
// if (useAsyncComm)
|
||||
// filter.SetUseAsynchronousCommunication();
|
||||
// else
|
||||
// filter.SetUseSynchronousCommunication();
|
||||
if (useAsyncComm)
|
||||
filter.SetUseAsynchronousCommunication();
|
||||
else
|
||||
filter.SetUseSynchronousCommunication();
|
||||
|
||||
if (useBlockIds)
|
||||
filter.SetBlockIDs(blockIds);
|
||||
@ -578,7 +578,6 @@ void TestPartitionedDataSet(vtkm::Id nPerRank,
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void TestStreamlineFiltersMPI()
|
||||
{
|
||||
auto comm = vtkm::cont::EnvironmentTracker::GetCommunicator();
|
||||
|
Loading…
Reference in New Issue
Block a user