Static methods

staticfromCOO<T>(ctx:Context, rowInd:Tensor_I32, colInd:Tensor_I32, values:TensorArg<T>, nRows:Int, nCols:Int):SparseMatrix<T>

staticfromCSR<T>(ctx:Context, rowPtr:Tensor_I32, colInd:Tensor_I32, values:TensorArg<T>, nRows:Int, nCols:Int):SparseMatrix<T>

staticfromTriplets<T>(rows:Int, cols:Int, triplets:Array<SparseTriplet<T>>):SparseMatrix<T>

Constructor

new(rows:Int, cols:Int)

Variables

finalcols:Int

read onlynnz:Int

finalrows:Int

Methods

add(other:SparseMatrix<T>, zero:T):SparseMatrix<T>

clear():Void

get(row:Int, col:Int, defaultValue:T):T

has(row:Int, col:Int):Bool

matVec(vector:Array<T>, zero:T):Array<T>

mul(other:SparseMatrix<T>, zero:T):SparseMatrix<T>

remove(row:Int, col:Int):Bool

scale(value:T):SparseMatrix<T>

set(row:Int, col:Int, value:T):Void

sub(other:SparseMatrix<T>, zero:T):SparseMatrix<T>

toDense(defaultValue:T):Array<T>