public static extern cusparseStatus cusparseZcsr2csc(cusparseContext handle, int m, int n, int nnz, CUdeviceptr csrVal, CUdeviceptr csrRowPtr, CUdeviceptr csrColInd, CUdeviceptr cscVal, CUdeviceptr cscRowInd, CUdeviceptr cscColPtr, cusparseAction copyValues, cusparseIndexBase idxBase);
		public static extern cusparseStatus cusparseZgebsr2gebsc(cusparseContext handle,
											  int mb,
											  int nb,
											  int nnzb,
											  CUdeviceptr bsrVal,
											  CUdeviceptr bsrRowPtr,
											  CUdeviceptr bsrColInd,
											  int rowBlockDim,
											  int colBlockDim,
											  CUdeviceptr bscVal,
											  CUdeviceptr bscRowInd,
											  CUdeviceptr bscColPtr,
											  cusparseAction copyValues,
											  cusparseIndexBase baseIdx,
											  CUdeviceptr pBuffer);
Ejemplo n.º 3
0
 private static extern CUSPARSEStatus cusparseDcsr2csc_v2(cusparseHandle handle, int m, int n, int nnz, IntPtr csrVal, IntPtr csrRowPtr, IntPtr csrColInd, IntPtr cscVal, IntPtr cscRowInd, IntPtr cscColPtr, cusparseAction copyvalues, cusparseIndexBase bs);
Ejemplo n.º 4
0
 public CUSPARSEStatus CusparseDcsr2csc(cusparseHandle handle, int m, int n, int nnz, IntPtr csrVal, IntPtr csrRowPtr, IntPtr csrColInd, IntPtr cscVal, IntPtr cscRowInd, IntPtr cscColPtr, cusparseAction copyvalues, cusparseIndexBase bs)
 {
     return(cusparseDcsr2csc_v2(handle, m, n, nnz, csrVal, csrRowPtr, csrColInd, cscVal, cscRowInd, cscColPtr, copyvalues, bs));
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Converts the matrix in CSR format defined with the three arrays csrVal, csrRow and csrCol into matrix A in CSC format defined by array cscVal, cscRow, cscCol.
 /// The resultng matrix can also be seen as the transpose of the original sparse matrix. This routine can also be used to convert a matrix in CSC format into a matrix in CSR format.
 /// </summary>
 /// <param name="m">number of rows of the matrix A; m must be at least zero.</param>
 /// <param name="n">number of columns of the matrix A; n must be at least zero.</param>
 /// <param name="nnz">number of non-zero elements of matrix A.</param>
 /// <param name="csrVal">array of nnz elements, where nnz is the number of non-zero elements and can be obtained from csrRow[m] - csrRow[0].</param>
 /// <param name="csrRow">array of m+1 indices.</param>
 /// <param name="csrCol">array of nnz column indices.</param>
 /// <param name="cscVal">array of nnz elements, where nnz is the number of non-zero elements and can be obtained from csrCol[n] - csrCol[0]. if copyValues is non-zero, updated array.</param>
 /// <param name="cscRow">updated array of nnz row indices.</param>
 /// <param name="cscCol">updated array of n+1 index elements.</param>
 /// <param name="copyValues">if Symbloic, cscVal array is not filled.</param>
 /// <param name="bs">base index.</param>
 public abstract void CSR2CSC(int m, int n, int nnz, double[] csrVal, int[] csrRow, int[] csrCol, double[] cscVal, int[] cscRow, int[] cscCol, cusparseAction copyValues = cusparseAction.Numeric, cusparseIndexBase bs = cusparseIndexBase.Zero);
Ejemplo n.º 6
0
        public override void CSR2CSC(int m, int n, int nnz, double[] csrVal, int[] csrRow, int[] csrCol, double[] cscVal, int[] cscRow, int[] cscCol, cusparseAction copyValues = cusparseAction.Numeric, cusparseIndexBase bs = cusparseIndexBase.Zero)
        {
            CUdeviceptr ptrcsrv = GetDeviceMemory(csrVal);
            CUdeviceptr ptrcsrr = GetDeviceMemory(csrRow);
            CUdeviceptr ptrcsrc = GetDeviceMemory(csrCol);

            CUdeviceptr ptrcscv = GetDeviceMemory(cscVal);
            CUdeviceptr ptrcscr = GetDeviceMemory(cscRow);
            CUdeviceptr ptrcscc = GetDeviceMemory(cscCol);

            LastStatus = _driver.CusparseDcsr2csc(_sparse, m, n, nnz, ptrcsrv.Pointer, ptrcsrr.Pointer, ptrcsrc.Pointer, ptrcscv.Pointer, ptrcscr.Pointer, ptrcscc.Pointer, copyValues, bs);
        }
Ejemplo n.º 7
0
 public CUSPARSEStatus CusparseDcsr2csc(cusparseHandle handle, int m, int n, int nnz, IntPtr csrVal, IntPtr csrRowPtr, IntPtr csrColInd, IntPtr cscVal, IntPtr cscRowInd, IntPtr cscColPtr, cusparseAction copyvalues, cusparseIndexBase bs)
 {
     return cusparseDcsr2csc_v2(handle, m, n, nnz, csrVal, csrRowPtr, csrColInd, cscVal, cscRowInd, cscColPtr, copyvalues, bs);
 }
Ejemplo n.º 8
0
 private static extern CUSPARSEStatus cusparseDcsr2csc_v2(cusparseHandle handle, int m, int n, int nnz, IntPtr csrVal, IntPtr csrRowPtr, IntPtr csrColInd, IntPtr cscVal, IntPtr cscRowInd, IntPtr cscColPtr, cusparseAction copyvalues, cusparseIndexBase bs);
Ejemplo n.º 9
0
 public static extern cusparseStatus cusparseCsr2cscEx(cusparseContext handle,
                                       int m, 
                                       int n, 
                                       int nnz,
                                       CUdeviceptr csrSortedVal, 
                                       cudaDataType csrSortedValtype,
                                       CUdeviceptr csrSortedRowPtr, 
                                       CUdeviceptr csrSortedColInd, 
                                       CUdeviceptr cscSortedVal, 
                                       cudaDataType cscSortedValtype,
                                       CUdeviceptr cscSortedRowInd, 
                                       CUdeviceptr cscSortedColPtr, 
                                       cusparseAction copyValues, 
                                       cusparseIndexBase idxBase,
                                       cudaDataType executiontype);