graph
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | Static Public Member Functions | Public Attributes | Private Attributes | List of all members
COO< Index > Class Template Reference

A COO matrix backed by CUDA Unified Memory, with a CSR rowPtr. More...

#include <coo.hpp>

Public Member Functions

 COO ()
 empty CSR More...
 
HOST DEVICE uint64_t nnz () const
 number of non-zeros More...
 
uint64_t num_nodes () const
 number of unique row/col indices More...
 
HOST DEVICE uint64_t num_rows () const
 number of matrix rows More...
 
COOView< Index > view () const
 create a COOView for this COO More...
 
const Index * row_ptr ()
 row offset array More...
 
const Index * col_ind ()
 column index array More...
 
const Index * row_ind ()
 

Static Public Member Functions

static COO< Index > from_edgelist (const EdgeList &es, bool(*edgeFilter)(const Edge &)=nullptr)
 

Public Attributes

Vector< Index > rowPtr_
 offset in col_ that each row starts at More...
 
Vector< Index > colInd_
 non-zero column indices More...
 
Vector< Index > rowInd_
 non-zero row indices More...
 

Private Attributes

Index maxCol_
 

Detailed Description

template<typename Index>
class COO< Index >

A COO matrix backed by CUDA Unified Memory, with a CSR rowPtr.

Copying to a GPU kernel by value will cause the underling memory to be copied as well. For read-only GPU access, use the view() method to get a lightweight reference to the data.

Constructor & Destructor Documentation

◆ COO()

template<typename Index >
COO< Index >::COO ( )

empty CSR

Member Function Documentation

◆ col_ind()

template<typename Index>
const Index* COO< Index >::col_ind ( )
inline

column index array

◆ from_edgelist()

template<typename Index >
COO< Index > COO< Index >::from_edgelist ( const EdgeList es,
bool(*)(const Edge &)  edgeFilter = nullptr 
)
static

Build a COO from an EdgeList

Do not include edges where edgeFilter(edge) returns true

◆ nnz()

template<typename Index>
HOST DEVICE uint64_t COO< Index >::nnz ( ) const
inline

number of non-zeros

◆ num_nodes()

template<typename Index >
uint64_t COO< Index >::num_nodes ( ) const

number of unique row/col indices

◆ num_rows()

template<typename Index >
HOST DEVICE uint64_t COO< Index >::num_rows ( ) const

number of matrix rows

◆ row_ind()

template<typename Index>
const Index* COO< Index >::row_ind ( )
inline

◆ row_ptr()

template<typename Index>
const Index* COO< Index >::row_ptr ( )
inline

row offset array

◆ view()

template<typename Index >
COOView< Index > COO< Index >::view ( ) const

create a COOView for this COO

Member Data Documentation

◆ colInd_

template<typename Index>
Vector<Index> COO< Index >::colInd_

non-zero column indices

◆ maxCol_

template<typename Index>
Index COO< Index >::maxCol_
private

◆ rowInd_

template<typename Index>
Vector<Index> COO< Index >::rowInd_

non-zero row indices

◆ rowPtr_

template<typename Index>
Vector<Index> COO< Index >::rowPtr_

offset in col_ that each row starts at


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