ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
cloudViewer::core::AdvancedIndexer Class Reference

#include <AdvancedIndexing.h>

Collaboration diagram for cloudViewer::core::AdvancedIndexer:

Public Types

enum class  AdvancedIndexerMode { SET , GET }
 

Public Member Functions

 AdvancedIndexer (const Tensor &src, const Tensor &dst, const std::vector< Tensor > &index_tensors, const SizeVector &indexed_shape, const SizeVector &indexed_strides, AdvancedIndexerMode mode)
 
CLOUDVIEWER_HOST_DEVICE char * GetInputPtr (int64_t workload_idx) const
 
CLOUDVIEWER_HOST_DEVICE char * GetOutputPtr (int64_t workload_idx) const
 
CLOUDVIEWER_HOST_DEVICE int64_t GetIndexedOffset (int64_t workload_idx) const
 
int64_t NumWorkloads () const
 

Protected Attributes

Indexer indexer_
 
AdvancedIndexerMode mode_
 
int64_t num_indices_
 
int64_t element_byte_size_
 
int64_t indexed_shape_ [MAX_DIMS]
 
int64_t indexed_strides_ [MAX_DIMS]
 

Detailed Description

AdvancedIndexer exposes an interface similar to Indexer, with support for advanced indexing.

In particular, AdvancedIndexer contains an Indexer instance to iterate src, dst and index tensors. AdvancedIndexer also contains various properties for advanced indexing.

To construct AdvancedIndexer, one must use the tensors and index tensors preprocessed by AdvancedIndexPreprocessor.

Definition at line 117 of file AdvancedIndexing.h.

Member Enumeration Documentation

◆ AdvancedIndexerMode

Enumerator
SET 
GET 

Definition at line 119 of file AdvancedIndexing.h.

Constructor & Destructor Documentation

◆ AdvancedIndexer()

cloudViewer::core::AdvancedIndexer::AdvancedIndexer ( const Tensor src,
const Tensor dst,
const std::vector< Tensor > &  index_tensors,
const SizeVector indexed_shape,
const SizeVector indexed_strides,
AdvancedIndexerMode  mode 
)
inline

Member Function Documentation

◆ GetIndexedOffset()

CLOUDVIEWER_HOST_DEVICE int64_t cloudViewer::core::AdvancedIndexer::GetIndexedOffset ( int64_t  workload_idx) const
inline

◆ GetInputPtr()

CLOUDVIEWER_HOST_DEVICE char* cloudViewer::core::AdvancedIndexer::GetInputPtr ( int64_t  workload_idx) const
inline

◆ GetOutputPtr()

CLOUDVIEWER_HOST_DEVICE char* cloudViewer::core::AdvancedIndexer::GetOutputPtr ( int64_t  workload_idx) const
inline

◆ NumWorkloads()

int64_t cloudViewer::core::AdvancedIndexer::NumWorkloads ( ) const
inline

Member Data Documentation

◆ element_byte_size_

int64_t cloudViewer::core::AdvancedIndexer::element_byte_size_
protected

Definition at line 204 of file AdvancedIndexing.h.

Referenced by AdvancedIndexer(), GetInputPtr(), and GetOutputPtr().

◆ indexed_shape_

int64_t cloudViewer::core::AdvancedIndexer::indexed_shape_[MAX_DIMS]
protected

Definition at line 205 of file AdvancedIndexing.h.

Referenced by AdvancedIndexer(), and GetIndexedOffset().

◆ indexed_strides_

int64_t cloudViewer::core::AdvancedIndexer::indexed_strides_[MAX_DIMS]
protected

Definition at line 206 of file AdvancedIndexing.h.

Referenced by AdvancedIndexer(), and GetIndexedOffset().

◆ indexer_

Indexer cloudViewer::core::AdvancedIndexer::indexer_
protected

◆ mode_

AdvancedIndexerMode cloudViewer::core::AdvancedIndexer::mode_
protected

Definition at line 202 of file AdvancedIndexing.h.

Referenced by GetInputPtr(), and GetOutputPtr().

◆ num_indices_

int64_t cloudViewer::core::AdvancedIndexer::num_indices_
protected

Definition at line 203 of file AdvancedIndexing.h.

Referenced by AdvancedIndexer(), and GetIndexedOffset().


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