Go to the documentation of this file.
18 #ifndef viskores_worklet_WorkletMapTopology_h
19 #define viskores_worklet_WorkletMapTopology_h
52 template <
typename WorkletType>
53 class DispatcherMapTopology;
58 struct WorkletMapTopologyBase : viskores::worklet::internal::WorkletBase
60 template <
typename Worklet>
78 template <
typename VisitTopology,
typename Inc
identTopology>
174 template <
typename OutToInArrayType,
175 typename VisitArrayType,
176 typename ThreadToOutArrayType,
177 typename InputDomainType>
182 const OutToInArrayType& outToIn,
183 const VisitArrayType& visit,
184 const ThreadToOutArrayType& threadToOut,
185 const InputDomainType& connectivity)
const
187 const viskores::Id outIndex = threadToOut.Get(threadIndex);
188 return viskores::exec::arg::
189 ThreadIndicesTopologyMap<InputDomainType, viskores::exec::arg::CustomScatterOrMaskTag>(
190 threadIndex, outToIn.Get(outIndex), visit.Get(outIndex), outIndex, connectivity);
201 std::is_same<ScatterType, viskores::worklet::ScatterIdentity>::value;
202 static constexpr
bool IsMaskNone = std::is_same<MaskType, viskores::worklet::MaskNone>::value;
204 template <
bool Cond,
typename ReturnType>
210 template <
typename OutToInArrayType,
211 typename VisitArrayType,
212 typename ThreadToOutArrayType,
213 typename InputDomainType,
225 const InputDomainType& connectivity)
const
227 return viskores::exec::arg::
228 ThreadIndicesTopologyMap<InputDomainType, viskores::exec::arg::DefaultScatterAndMaskTag>(
229 threadIndex3D, threadIndex1D, connectivity);
234 template <
typename OutToInArrayType,
235 typename VisitArrayType,
236 typename ThreadToOutArrayType,
237 typename InputDomainType,
246 const OutToInArrayType& outToIn,
247 const VisitArrayType& visit,
248 const ThreadToOutArrayType& threadToOut,
249 const InputDomainType& connectivity)
const
251 const viskores::Id outIndex = threadToOut.Get(threadIndex1D);
252 return viskores::exec::arg::
253 ThreadIndicesTopologyMap<InputDomainType, viskores::exec::arg::CustomScatterOrMaskTag>(
256 outToIn.Get(outIndex),
266 :
public WorkletMapTopology<viskores::TopologyElementTagCell, viskores::TopologyElementTagPoint>
269 #ifndef VISKORES_DOXYGEN_ONLY
281 #else // VISKORES_DOXYGEN_ONLY
360 struct WholeArrayIn : viskores::worklet::internal::WorkletBase::WholeArrayIn
365 struct WholeArrayOut : viskores::worklet::internal::WorkletBase::WholeArrayOut
380 template <
typename VisitTopology = Cell,
typename Inc
identTopology = Po
int>
382 : viskores::worklet::internal::WorkletBase::WholeCellSetIn<VisitTopology, IncidentTopology>
387 struct ExecObject : viskores::worklet::internal::WorkletBase::ExecObject
398 struct _1 : viskores::worklet::internal::WorkletBase::_1
418 IncidentTopologyType>::IncidentElementCount
428 IncidentTopologyType>::IncidentElementIndices
458 struct Device : viskores::worklet::internal::WorkletBase::Device
463 #endif // VISKORES_DOXYGEN_ONLY
469 :
public WorkletMapTopology<viskores::TopologyElementTagPoint, viskores::TopologyElementTagCell>
472 #ifndef VISKORES_DOXYGEN_ONLY
484 #else // VISKORES_DOXYGEN_ONLY
563 struct WholeArrayIn : viskores::worklet::internal::WorkletBase::WholeArrayIn
568 struct WholeArrayOut : viskores::worklet::internal::WorkletBase::WholeArrayOut
583 template <
typename VisitTopology = Cell,
typename Inc
identTopology = Po
int>
585 : viskores::worklet::internal::WorkletBase::WholeCellSetIn<VisitTopology, IncidentTopology>
590 struct ExecObject : viskores::worklet::internal::WorkletBase::ExecObject
601 struct _1 : viskores::worklet::internal::WorkletBase::_1
612 IncidentTopologyType>::IncidentElementCount
622 IncidentTopologyType>::IncidentElementIndices
652 struct Device : viskores::worklet::internal::WorkletBase::Device
657 #endif // VISKORES_DOXYGEN_ONLY
663 #endif //viskores_worklet_WorkletMapTopology_h
Base class for worklets that map topology elements onto each other.
Definition: WorkletMapTopology.h:79
Transport tag for in-place arrays.
Definition: TransportTagArrayInOut.h:41
A control signature tag for input fields on the cells of the topology.
Definition: WorkletMapTopology.h:299
The ExecutionSignature tag to use to get the thread indices.
Definition: WorkletMapTopology.h:453
The Array type check passes for any object that behaves like an ArrayHandle class and can be passed t...
Definition: TypeCheckTagArrayIn.h:39
ControlSignature tag for whole input/output arrays.
Definition: WorkletMapTopology.h:375
The ExecutionSignature tag to get the indices of visited elements.
Definition: IncidentElementIndices.h:41
typename std::enable_if< Cond, ReturnType >::type EnableFnWhen
Definition: WorkletMapTopology.h:205
An execution signature tag for getting the cell shape.
Definition: WorkletMapTopology.h:141
A tag used to identify the cell elements in a topology.
Definition: TopologyElementTag.h:32
A control signature tag for input fields from the visited topology.
Definition: WorkletMapTopology.h:88
The ExecutionSignature tag to use to get the thread indices.
Definition: ThreadIndices.h:52
Uses spaces optimizations when using MaskNone and ScatterIdentity.
Definition: ThreadIndicesTopologyMap.h:82
A control signature tag for input fields on the points of the topology.
Definition: WorkletMapTopology.h:308
An execution signature tag to get the number of incident elements.
Definition: WorkletMapTopology.h:154
The ExecutionSignature tag to use to get the output index.
Definition: WorkletMapTopology.h:642
The ExecutionSignature tag to use to get the output index.
Definition: WorkletMapTopology.h:448
Argument placeholders for an ExecutionSignature.
Definition: WorkletMapTopology.h:398
A control signature tag for input connectivity.
Definition: WorkletMapTopology.h:289
A control signature tag for output fields.
Definition: WorkletMapTopology.h:107
#define viskoresNotUsed(parameter_name)
Simple macro to identify a parameter as unused.
Definition: ExportMacros.h:136
A control signature tag for input-output (in-place) fields.
Definition: WorkletMapTopology.h:349
Transport tag for input arrays.
Definition: TransportTagCellSetIn.h:40
An execution signature tag to get the shape of the visited cell.
Definition: WorkletMapTopology.h:406
The Array type check passes for any object that behaves like an ArrayHandle class and can be passed t...
Definition: TypeCheckTagArrayInOut.h:39
#define VISKORES_SUPPRESS_EXEC_WARNINGS
Definition: ExportMacros.h:61
A control signature tag for input fields on the cells of the topology.
Definition: WorkletMapTopology.h:511
A control signature tag for input-output (in-place) fields.
Definition: WorkletMapTopology.h:354
Check for a CellSet-like object.
Definition: TypeCheckTagCellSet.h:34
The ExecutionSignature tag to use to get the cell shape.
Definition: exec/arg/CellShape.h:42
A control signature tag for output fields.
Definition: WorkletMapTopology.h:339
static constexpr bool IsMaskNone
Definition: WorkletMapTopology.h:202
ControlSignature tag for whole input arrays.
Definition: WorkletMapTopology.h:563
Base class for worklets that map from Points to Cells.
Definition: WorkletMapTopology.h:265
An execution signature tag to get the number of incident points.
Definition: WorkletMapTopology.h:416
Fetch tag for getting topology information.
Definition: FetchTagCellSetIn.h:37
ControlSignature tag for whole input/output arrays.
Definition: WorkletMapTopology.h:370
Container for thread indices in a topology map.
Definition: ThreadIndicesTopologyMap.h:103
A control signature tag for input fields from the visited topology.
Definition: WorkletMapTopology.h:518
ExecutionSignature tag for getting the device adapter tag.
Definition: WorkletMapTopology.h:458
A tag used to identify the point elements in a topology.
Definition: TopologyElementTag.h:42
The base class for all tags used in a ControlSignature.
Definition: ControlSignatureTagBase.h:44
ControlSignature tag for whole input arrays.
Definition: WorkletMapTopology.h:360
An execution signature tag to get the indices of the incident points.
Definition: WorkletMapTopology.h:426
viskores::exec::arg::ThreadIndicesTopologyMap< InputDomainType, viskores::exec::arg::CustomScatterOrMaskTag > GetThreadIndices(viskores::Id threadIndex, const OutToInArrayType &outToIn, const VisitArrayType &visit, const ThreadToOutArrayType &threadToOut, const InputDomainType &connectivity) const
Topology map worklets use topology map indices.
Definition: WorkletMapTopology.h:181
Fetch tag for in-place modifying array values with direct indexing.
Definition: FetchTagArrayDirectInOut.h:47
Base class for worklets that map from Cells to Points.
Definition: WorkletMapTopology.h:468
The ExecutionSignature tag to use to get the work index.
Definition: WorkletMapTopology.h:433
The ExecutionSignature tag to get the number of incident elements.
Definition: IncidentElementCount.h:48
The ExecutionSignature tag to use to get the visit index.
Definition: VisitIndex.h:54
viskores::Int64 Id
Base type to use to index arrays.
Definition: Types.h:235
Groups connected points that have the same field value.
Definition: Atomic.h:27
A control signature tag for input fields from the incident topology.
Definition: WorkletMapTopology.h:98
The ExecutionSignature tag to use to get the output index.
Definition: OutputIndex.h:52
EnableFnWhen< S &&M, viskores::exec::arg::ThreadIndicesTopologyMap< InputDomainType, viskores::exec::arg::DefaultScatterAndMaskTag > > GetThreadIndices(viskores::Id threadIndex1D, const viskores::Id3 &threadIndex3D, const OutToInArrayType &, const VisitArrayType &, const ThreadToOutArrayType &, const InputDomainType &connectivity) const
Optimized for ScatterIdentity and MaskNone.
Definition: WorkletMapTopology.h:220
Dispatcher for worklets that inherit from WorkletMapTopology.
Definition: DispatcherMapTopology.h:39
The ExecutionSignature tag to use to get the thread indices.
Definition: WorkletMapTopology.h:647
ControlSignature tag for whole output arrays.
Definition: WorkletMapTopology.h:568
A control signature tag for output fields.
Definition: WorkletMapTopology.h:537
An execution signature tag to get the number of incident cells.
Definition: WorkletMapTopology.h:610
Transport tag for output arrays.
Definition: TransportTagArrayOut.h:40
ControlSignature tag for whole input/output arrays.
Definition: WorkletMapTopology.h:573
A control signature tag for input connectivity.
Definition: WorkletMapTopology.h:492
Fetch tag for getting array values determined by topology connections.
Definition: FetchTagArrayTopologyMapIn.h:48
A control signature tag for input-output (in-place) fields.
Definition: WorkletMapTopology.h:552
Argument placeholders for an ExecutionSignature.
Definition: WorkletMapTopology.h:601
An execution signature tag to get the indices of from elements.
Definition: WorkletMapTopology.h:167
The Array type check passes for any object that behaves like an ArrayHandle class and can be passed t...
Definition: TypeCheckTagArrayOut.h:39
The ExecutionSignature tag to use to get the visit index.
Definition: WorkletMapTopology.h:632
ControlSignature tag for whole output arrays.
Definition: WorkletMapTopology.h:365
Transport tag for input arrays in topology maps.
Definition: TransportTagTopologyFieldIn.h:44
The ExecutionSignature tag to use to get the visit index.
Definition: WorkletMapTopology.h:438
Fetch tag for getting array values with direct indexing.
Definition: FetchTagArrayDirectIn.h:37
An execution signature tag to get the indices of the incident cells.
Definition: WorkletMapTopology.h:620
ControlSignature tag for whole input topology.
Definition: WorkletMapTopology.h:584
ControlSignature tag for execution object inputs.
Definition: WorkletMapTopology.h:387
A control signature tag for output fields.
Definition: WorkletMapTopology.h:334
A control signature tag for input fields on the points of the topology.
Definition: WorkletMapTopology.h:502
A control signature tag for input fields from the visited topology.
Definition: WorkletMapTopology.h:315
Fetch tag for setting array values with direct indexing.
Definition: FetchTagArrayDirectOut.h:39
EnableFnWhen< !(S &&M), viskores::exec::arg::ThreadIndicesTopologyMap< InputDomainType, viskores::exec::arg::CustomScatterOrMaskTag > > GetThreadIndices(viskores::Id threadIndex1D, const viskores::Id3 &threadIndex3D, const OutToInArrayType &outToIn, const VisitArrayType &visit, const ThreadToOutArrayType &threadToOut, const InputDomainType &connectivity) const
Default version.
Definition: WorkletMapTopology.h:244
A control signature tag for input fields from the incident topology.
Definition: WorkletMapTopology.h:323
ExecutionSignature tag for getting the device adapter tag.
Definition: WorkletMapTopology.h:652
ControlSignature tag for whole input topology.
Definition: WorkletMapTopology.h:381
A control signature tag for input-output (in-place) fields.
Definition: WorkletMapTopology.h:557
static constexpr bool IsScatterIdentity
In the remaining methods and constexpr we determine at compilation time which method definition will ...
Definition: WorkletMapTopology.h:200
A control signature tag for input fields from the incident topology.
Definition: WorkletMapTopology.h:526
A control signature tag for output fields.
Definition: WorkletMapTopology.h:542
ControlSignature tag for execution object inputs.
Definition: WorkletMapTopology.h:590
A control signature tag for input connectivity.
Definition: WorkletMapTopology.h:130
ControlSignature tag for whole input/output arrays.
Definition: WorkletMapTopology.h:578
Used for when not using MaskNone and ScatterIdentity.
Definition: ThreadIndicesTopologyMap.h:88
The ExecutionSignature tag to use to get the work index.
Definition: WorkletMapTopology.h:627
#define VISKORES_EXEC
Definition: ExportMacros.h:59
The ExecutionSignature tag to use to get the work index.
Definition: WorkIndex.h:47
A control signature tag for input-output (in-place) fields from the visited topology.
Definition: WorkletMapTopology.h:117