\doxysection{gko::\+matrix::\+Csr\texorpdfstring{$<$}{<} Value\+Type, Index\+Type \texorpdfstring{$>$}{>}::\+sparselib Class Reference}
\hypertarget{classgko_1_1matrix_1_1Csr_1_1sparselib}{}\label{classgko_1_1matrix_1_1Csr_1_1sparselib}\index{gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib@{gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib}}


sparselib is a \doxylink{classgko_1_1matrix_1_1Csr_1_1strategy__type}{strategy\+\_\+type} which uses the sparselib csr.  




{\ttfamily \+\#include $<$ginkgo/\+core/\+matrix/\+csr.\+hpp$>$}



Inheritance diagram for gko::\+matrix::\+Csr\texorpdfstring{$<$}{<} Value\+Type, Index\+Type \texorpdfstring{$>$}{>}::\+sparselib:\+
\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=221pt]{classgko_1_1matrix_1_1Csr_1_1sparselib__inherit__graph}
\end{center}
\end{figure}


Collaboration diagram for gko::\+matrix::\+Csr\texorpdfstring{$<$}{<} Value\+Type, Index\+Type \texorpdfstring{$>$}{>}::\+sparselib:\+
\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=221pt]{classgko_1_1matrix_1_1Csr_1_1sparselib__coll__graph}
\end{center}
\end{figure}
\doxysubsubsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\Hypertarget{classgko_1_1matrix_1_1Csr_1_1sparselib_a2b50338d0f7679bc94b09d63341c5c6f}\label{classgko_1_1matrix_1_1Csr_1_1sparselib_a2b50338d0f7679bc94b09d63341c5c6f} 
{\bfseries sparselib} ()
\begin{DoxyCompactList}\small\item\em Creates a sparselib strategy. \end{DoxyCompactList}\item 
void \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr_1_1sparselib_a2167e481d117f8208525c15cf6b3bb4d}{process}} (const \doxymbox{\hyperlink{classgko_1_1array}{array}}$<$ index\+\_\+type $>$ \&mtx\+\_\+row\+\_\+ptrs, \doxymbox{\hyperlink{classgko_1_1array}{array}}$<$ index\+\_\+type $>$ \texorpdfstring{$\ast$}{*}mtx\+\_\+srow) override
\begin{DoxyCompactList}\small\item\em Computes srow according to row pointers. \end{DoxyCompactList}\item 
int64\+\_\+t \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr_1_1sparselib_a106f7ba1d05091e56d27c3b50f141740}{clac\+\_\+size}} (const int64\+\_\+t nnz) override
\begin{DoxyCompactList}\small\item\em Computes the srow size according to the number of nonzeros. \end{DoxyCompactList}\item 
std::\+shared\+\_\+ptr$<$ \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr_1_1strategy__type_aae6804f7a0b899f03bc0d5e0f139129c}{strategy\+\_\+type}} $>$ \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr_1_1sparselib_add8e101467e4e4cb44da0fbaa2c524c1}{copy}} () override
\begin{DoxyCompactList}\small\item\em Copy a strategy. \end{DoxyCompactList}\end{DoxyCompactItemize}
\doxysubsection*{Public Member Functions inherited from \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr_1_1strategy__type}{gko::\+matrix::\+\+Csr$<$ Value\+Type, Index\+Type $>$::\+strategy\+\_\+type}}}
\begin{DoxyCompactItemize}
\item 
\doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr_1_1strategy__type_aae6804f7a0b899f03bc0d5e0f139129c}{strategy\+\_\+type}} (std::\+string name)
\begin{DoxyCompactList}\small\item\em Creates a \doxylink{classgko_1_1matrix_1_1Csr_1_1strategy__type}{strategy\+\_\+type}. \end{DoxyCompactList}\item 
std::\+string \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr_1_1strategy__type_a0c22b251b0c1dfd087a5c097488febe0}{get\+\_\+name}} ()
\begin{DoxyCompactList}\small\item\em Returns the name of strategy. \end{DoxyCompactList}\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
\subsubsection*{template$<$typename Value\+Type = default\+\_\+precision, typename Index\+Type = int32$>$\newline
class gko::\+matrix::\+\+Csr$<$ Value\+Type, Index\+Type $>$::\+sparselib}
sparselib is a \doxylink{classgko_1_1matrix_1_1Csr_1_1strategy__type}{strategy\+\_\+type} which uses the sparselib csr. 

\begin{DoxyNote}{Note}
Uses cusparse in cuda and hipsparse in hip. 
\end{DoxyNote}


\label{doc-func-members}
\Hypertarget{classgko_1_1matrix_1_1Csr_1_1sparselib_doc-func-members}
\doxysubsection{Member Function Documentation}
\Hypertarget{classgko_1_1matrix_1_1Csr_1_1sparselib_a106f7ba1d05091e56d27c3b50f141740}\index{gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib@{gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib}!clac\_size@{clac\_size}}
\index{clac\_size@{clac\_size}!gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib@{gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib}}
\doxysubsubsection{\texorpdfstring{clac\_size()}{clac\_size()}}
{\footnotesize\ttfamily \label{classgko_1_1matrix_1_1Csr_1_1sparselib_a106f7ba1d05091e56d27c3b50f141740} 
template$<$typename Value\+Type = default\+\_\+precision, typename Index\+Type = int32$>$ \\
int64\+\_\+t \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr}{gko::\+matrix::\+\+Csr}}$<$ Value\+Type, Index\+Type $>$::\+sparselib::\+clac\+\_\+size (\begin{DoxyParamCaption}\item[{const int64\+\_\+t}]{nnz}{}\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [override]}, {\ttfamily [virtual]}}



Computes the srow size according to the number of nonzeros. 


\begin{DoxyParams}{Parameters}
{\em nnz} & the number of nonzeros\\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
the size of srow 
\end{DoxyReturn}


Implements \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr_1_1strategy__type_a07a6dda9dd04ed8abd914f3a69f330f2}{gko::\+matrix::\+\+Csr$<$ Value\+Type, Index\+Type $>$::\+strategy\+\_\+type}}.

\Hypertarget{classgko_1_1matrix_1_1Csr_1_1sparselib_add8e101467e4e4cb44da0fbaa2c524c1}\index{gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib@{gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib}!copy@{copy}}
\index{copy@{copy}!gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib@{gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib}}
\doxysubsubsection{\texorpdfstring{copy()}{copy()}}
{\footnotesize\ttfamily \label{classgko_1_1matrix_1_1Csr_1_1sparselib_add8e101467e4e4cb44da0fbaa2c524c1} 
template$<$typename Value\+Type = default\+\_\+precision, typename Index\+Type = int32$>$ \\
std::\+shared\+\_\+ptr$<$ \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr_1_1strategy__type_aae6804f7a0b899f03bc0d5e0f139129c}{strategy\+\_\+type}} $>$ \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr}{gko::\+matrix::\+\+Csr}}$<$ Value\+Type, Index\+Type $>$::\+sparselib::\+copy (\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [override]}, {\ttfamily [virtual]}}



Copy a strategy. 

This is a workaround until strategies are revamped, since strategies like {\ttfamily \doxylink{classgko_1_1matrix_1_1Csr_1_1automatical}{automatical}} do not work when actually shared. 

Implements \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr_1_1strategy__type_a7d1561856f7ae17ca5e39076cb6c4207}{gko::\+matrix::\+\+Csr$<$ Value\+Type, Index\+Type $>$::\+strategy\+\_\+type}}.

\Hypertarget{classgko_1_1matrix_1_1Csr_1_1sparselib_a2167e481d117f8208525c15cf6b3bb4d}\index{gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib@{gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib}!process@{process}}
\index{process@{process}!gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib@{gko::matrix::Csr$<$ ValueType, IndexType $>$::sparselib}}
\doxysubsubsection{\texorpdfstring{process()}{process()}}
{\footnotesize\ttfamily \label{classgko_1_1matrix_1_1Csr_1_1sparselib_a2167e481d117f8208525c15cf6b3bb4d} 
template$<$typename Value\+Type = default\+\_\+precision, typename Index\+Type = int32$>$ \\
void \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr}{gko::\+matrix::\+\+Csr}}$<$ Value\+Type, Index\+Type $>$::\+sparselib::\+process (\begin{DoxyParamCaption}\item[{const \doxymbox{\hyperlink{classgko_1_1array}{array}}$<$ index\+\_\+type $>$ \&}]{mtx\+\_\+row\+\_\+ptrs}{, }\item[{\doxymbox{\hyperlink{classgko_1_1array}{array}}$<$ index\+\_\+type $>$ \texorpdfstring{$\ast$}{*}}]{mtx\+\_\+srow}{}\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [override]}, {\ttfamily [virtual]}}



Computes srow according to row pointers. 


\begin{DoxyParams}{Parameters}
{\em mtx\+\_\+row\+\_\+ptrs} & the row pointers of the matrix \\
\hline
{\em mtx\+\_\+srow} & the srow of the matrix \\
\hline
\end{DoxyParams}


Implements \doxymbox{\hyperlink{classgko_1_1matrix_1_1Csr_1_1strategy__type_a99ea39b16f0c281fdaf8c559f670c10b}{gko::\+matrix::\+\+Csr$<$ Value\+Type, Index\+Type $>$::\+strategy\+\_\+type}}.



The documentation for this class was generated from the following file:\+\begin{DoxyCompactItemize}
\item 
ginkgo/\+core/\+matrix/\+csr.\+hpp\end{DoxyCompactItemize}
