File view_matrix_csr_binary.hpp¶
Typedefs
-
using AllocatedBinaryCsrView = BinaryCsrViewAllocator<BinaryCsrView>¶
Allocates the memory, a
BinaryCsrViewprovides access to
-
class BinaryCsrView : public BinarySparseMatrix¶
- #include <view_matrix_csr_binary.hpp>
A two-dimensional view that provides row-wise access to binary values stored in a matrix in the compressed sparse row (CSR) format.
Subclassed by BinaryCsrViewAllocator< BinaryCsrView >
Public Types
Public Functions
-
inline BinaryCsrView(uint32 *indices, uint32 *indptr, uint32 numRows, uint32 numCols)¶
- Parameters:
indices – A pointer to an array of type
uint32, shape(numDenseElements), that stores the column indices of all dense elements explicitly stored in the matrixindptr – A pointer to an array of type
uint32, shape(numRows + 1), that stores the indices of the first element inindicesthat corresponds to a certain row. The index at the last position musts be equal tonumDenseElementsnumRows – The number of rows in the view
numCols – The number of columns in the view
-
inline BinaryCsrView(const BinaryCsrView &other)¶
- Parameters:
other – A const reference to an object of type
BinaryCsrViewthat should be copied
-
inline BinaryCsrView(BinaryCsrView &&other)¶
- Parameters:
other – A reference to an object of type
BinaryCsrViewthat should be moved
-
inline virtual ~BinaryCsrView() override¶
-
inline const_row operator[](uint32 row) const¶
Creates and returns a view that provides read-only access to a specific row in the view.
- Parameters:
row – The index of the row
- Returns:
An object of type
const_rowthat has been created
-
inline row operator[](uint32 row)¶
Creates and returns a view that provides access to a specific row in the view and allows to modify it.
- Parameters:
row – The index of the row
- Returns:
An object of type
rowthat has been created
-
inline BinarySparseMatrix::index_const_iterator indices_cbegin(uint32 row) const¶
Returns an
index_const_iteratorto the beginning of the indices in a specific row of the matrix.- Parameters:
row – The index of the row
- Returns:
An
index_const_iteratorto the beginning of the indices
-
inline BinarySparseMatrix::index_const_iterator indices_cend(uint32 row) const¶
Returns an
index_const_iteratorto the end of the indices in a specific row of the matrix.- Parameters:
row – The index of the row
- Returns:
An
index_const_iteratorto the end of the indices
-
inline BinarySparseMatrix::index_iterator indices_begin(uint32 row)¶
Returns an
index_iteratorto the beginning of the indices in a specific row of the matrix.- Parameters:
row – The index of the row
- Returns:
An
index_iteratorto the beginning of the indices
-
inline BinarySparseMatrix::index_iterator indices_end(uint32 row)¶
Returns an
index_iteratorto the end of the indices in a specific row of the matrix.- Parameters:
row – The index of the row
- Returns:
An
index_iteratorto the end of the indices
-
inline BinaryCsrView(uint32 *indices, uint32 *indptr, uint32 numRows, uint32 numCols)¶
-
template<typename Matrix>
class BinaryCsrViewAllocator : public Matrix¶ - #include <view_matrix_csr_binary.hpp>
Allocates the memory for a two-dimensional view that provides row-wise access to binary values stored in a matrix in the compressed sparse row (CSR) format.
- Template Parameters:
Matrix – The type of the view
Public Functions
-
inline BinaryCsrViewAllocator(uint32 numDenseElements, uint32 numRows, uint32 numCols)¶
- Parameters:
numDenseElements – The number of dense elements explicitly stored in the view
numRows – The number of rows in the view
numCols – The number of columns in the view
-
inline BinaryCsrViewAllocator(const BinaryCsrViewAllocator<Matrix> &other)¶
- Parameters:
other – A reference to an object of type
BinaryCsrViewAllocatorthat should be copied
-
inline BinaryCsrViewAllocator(BinaryCsrViewAllocator<Matrix> &&other)¶
- Parameters:
other – A reference to an object of type
BinaryCsrViewAllocatorthat should be moved
-
inline virtual ~BinaryCsrViewAllocator() override¶