Accumulate (row, col, ival) tuples from inds (generic version).
Accumulate (row, col, ival) tuples from inds (generic version). nr and nc are row and column bounds
Accumulate (row, col, ival) tuples from inds (generic version) into omat.
Accumulate (row, col, ival) tuples from inds (generic version) into omat. nr and nc are row and column bounds
Accumulate (row, col, fval) tuples from inds (generic version).
Accumulate (row, col, fval) tuples from inds (generic version). nr and nc are row and column bounds
Accumulate (row, col, fval) tuples from inds (generic version) into omat.
Accumulate (row, col, fval) tuples from inds (generic version) into omat. nr and nc are row and column bounds
Accumulate (row, col, value) tuples from inds \\ vals (generic version).
Accumulate (row, col, value) tuples from inds \\ vals (generic version). nr and nc are row and column bounds
Accumulate (row, col, value) tuples from inds \\ vals (generic version) into omat.
Accumulate (row, col, value) tuples from inds \\ vals (generic version) into omat. nr and nc are row and column bounds
Accumulate (row, col, fval) tuples from inds.
Accumulate (row, col, fval) tuples from inds. nr and nc are row and column bounds
Accumulate (row, col, fval) tuples from inds into omat.
Accumulate (row, col, fval) tuples from inds into omat. nr and nc are row and column bounds
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr and nc are row and column bounds
Accumulate (row, col, value) tuples from inds \\ vals into omat.
Accumulate (row, col, value) tuples from inds \\ vals into omat. nr and nc are row and column bounds
Accumulate (row, col, fval) tuples from inds.
Accumulate (row, col, fval) tuples from inds. nr and nc are row and column bounds
Accumulate (row, col, fval) tuples from inds into omat.
Accumulate (row, col, fval) tuples from inds into omat. nr and nc are row and column bounds
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr and nc are row and column bounds
Accumulate (row, col, value) tuples from inds \\ vals into omat.
Accumulate (row, col, value) tuples from inds \\ vals into omat. nr and nc are row and column bounds
Accumulate (row, value) tuples from inds \\ vals.
Accumulate (row, value) tuples from inds \\ vals. inds can be a vector or two-column matrix
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr is row and bounds, ncols = 1
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr and nc are row and column bounds
Accumulate (row, value) tuples from inds \\ vals.
Accumulate (row, value) tuples from inds \\ vals. inds can be a vector or two-column matrix
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr is row and bounds, ncols = 1
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr and nc are row and column bounds
Accumulate (row, value) tuples from inds \\ vals.
Accumulate (row, value) tuples from inds \\ vals. inds can be a vector or two-column matrix
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr is row and bounds, ncols = 1
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr and nc are row and column bounds
Accumulate (row, value) tuples from inds \\ vals.
Accumulate (row, value) tuples from inds \\ vals. inds can be a vector or two-column matrix
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr is row and bounds, ncols = 1
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr and nc are row and column bounds
Accumulate (row, value) tuples from inds \\ vals.
Accumulate (row, value) tuples from inds \\ vals. Inds can be a vector or two-column matrix
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr is row and bounds, ncols = 1
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr and nc are row and column bounds
Accumulate (row, value) tuples from inds \\ vals.
Accumulate (row, value) tuples from inds \\ vals. Inds can be a vector or two-column matrix
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr is row and bounds, ncols = 1
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr and nc are row and column bounds
Accumulate (row, value) tuples from inds \\ vals.
Accumulate (row, value) tuples from inds \\ vals. inds can be a vector or two-column matrixs
Accumulate (row, value) tuples from inds \\ vals.
Accumulate (row, value) tuples from inds \\ vals. nr is row bound. Assumes 1 column
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr and nc are row and column bounds
Accumulate (row, value) tuples from inds \\ vals.
Accumulate (row, value) tuples from inds \\ vals. inds can be a vector or two-column matrix
Accumulate (row, value) tuples from inds \\ vals.
Accumulate (row, value) tuples from inds \\ vals. nr is row bound. Assumes 1 column
Accumulate (row, col, value) tuples from inds \\ vals.
Accumulate (row, col, value) tuples from inds \\ vals. nr and nc are row and column bounds
Legacy function to make a placeholder matrix with no storage.
Legacy function to make a placeholder matrix with no storage.
Make a float column vector from a range.
Make a float column vector from a vararg list.
Make a float column vector from a list of type T.
Make a float column vector from an array of Ints.
Make a float column vector from an array of Doubles.
Make a float column vector from an array of Floats.
sparse matrix-vector multiply in coordinate form.
sparse matrix-vector multiply in coordinate form. inds should be an nnz x 2 matrix containing row/column indices of the sparse matrix. vals is an nnz x 1 matrix of values of the sparse matrix. in is the input vector, out is the output vector. Note that the bounds of row/col indices are not checked.
Copies row i from a into row j of b.
Count distinct elements in a sorted array of rows.
Count distinct elements in a sorted array of rows. Returns (bptrs, iptrs), where bptrs points to a set of distinct rows, and iptrs gives the index in this list for each input row.
Make a string column vector from string arguments to this function.
Make a string column vector from a list of strings.
Make a string row vector from this calls vararg list.
Make a string row vector from a list of strings.
implicit to convert doubles to 1x1 FMats
Legacy function to make a placeholder matrix with no storage.
Make a double column vector from the varargs to this function.
Make a double column vector from a list of doubles.
Make a double column vector from a range.
Distribute the data in the vv matrix using indices in the indx matrix into the mats array.
Distribute the data in the vv matrix using indices in the indx matrix into the mats array. Left and right are the range of the output buffer indices. Element vv(i) goes into buffer number (indx(i)-left)
Distribute the data in the vv matrix using indices in the indx matrix into the mats array.
Distribute the data in the vv matrix using indices in the indx matrix into the mats array. Left and right are the range of the output buffer indices. Element vv(i) goes into buffer number (indx(i)-left)
Distribute the data in the vv matrix using indices in the indx matrix into the mats array.
Distribute the data in the vv matrix using indices in the indx matrix into the mats array. Left and right are the range of the output buffer indices. Element vv(i) goes into buffer number (indx(i)-left)
Make a double matrix of ones with the given dimensions.
Make a double row vector from a range.
Make a double row vector from the varargs to this function.
Make a double row vector from a list of doubles.
Make a double row vector from an array of doubles.
Make a double matrix of zeros of the given dimensions.
implicit to convert an FMat to a DMat
Legacy function to make a placeholder matrix with no storage.
Find non-zero linear indices
Find non-zero linear indices
Find non-zero linear indices
Find non-zero linear indices
Find non-zero linear indices
Find non-zero linear indices
Find non-zero linear indices
Find non-zero (row, col) tuples
Find non-zero (row, col) tuples
Find non-zero (row, col) tuples
Find non-zero (row, col) indices
Find non-zero (row, col) indices
Find non-zero (row, col) indices
Find non-zero (row, col) indices
Find non-zero (row, col, value) tuples
Find non-zero (row, col, value) tuples
Find non-zero (row, col, value) tuples
Find non-zero (row, col, value) tuples
Find non-zero (row, col, value) tuples
Find non-zero (row, col, value) tuples
Find non-zero (row, col, value) tuples
Reset timer and flop counters.
Reset timer and flop counters. Complement to flop which returns the time and flops since the last flip.
Wrap
Wrap
flip; code; val f=flop
around any code you want to profile. f is a tuple of (flops,time)
implicit to convert floats to 1x1 FMats
Returns the square root of v as a float, as an alternative to math.sqrt(v)'s double.
Convert from GPU double sparse to GPU double dense.
Convert from GPU float sparse to GPU float dense.
Convert from float sparse to double dense.
Convert from double sparse to double dense.
Convert from single dense to single dense.
Convert from double dense to double dense.
Legacy function to make a placeholder matrix with no storage.
Gets the leading diagonal of a matrix as a vector.
Gets the leading diagonal of a matrix as a vector. Works on most matrix types.
Example, with IMats:
scala> val a = 1\2\3\4 on 4\5\6\7 on 7\8\9\10 a: BIDMat.IMat = 1 2 3 4 4 5 6 7 7 8 9 10 scala> getdiag(a) res3: BIDMat.IMat = 1 5 9
Gets the leading diagonal of GLMat a as a GLMat vector.
Gets the leading diagonal of GIMat a as a GIMat vector.
Gets the leading diagonal of GDMat a as a GDMat vector.
Gets the leading diagonal of GMat a as a GMat vector.
Gets the leading diagonal of CMat a as a CMat vector.
Gets the leading diagonal of LMat a as a LMat vector.
Gets the leading diagonal of FMat a as an FMat vector.
Gets the leading diagonal of DMat a as a DMat vector.
Wrap
Wrap
flip; code; val g=gflop
around any code you want to profile. g is a tuple of (gflops,time)
Legacy function to make a placeholder matrix with no storage.
Make an integer matrix of ones in GPU memory.
Make an integer matrix of zeros in GPU memory.
Make a long matrix of ones in GPU memory.
Make a long matrix of zeros in GPU memory.
Make a float matrix of ones in GPU memory.
Legacy function to make a placeholder matrix with no storage.
Make a single-precision matrix of zeros in GPU memory.
implicit to convert an IMat to an FMat
Legacy function to make a placeholder matrix with no storage.
Make an integer column vector from this calls vararg list.
Make an integer column vector from a List.
Make an integer column vector from a tuple to support 0->5 syntax for ranges.
Make an integer column vector from a range.
implicit to convert ints to 1x1 IMats
Compute the inverse permutation to a given integer permutation matrix.
Compute the inverse permutation to a given integer permutation matrix. i.e. given a vector ii which is a one-to-one map of 0...(n-1) to 0...(n-1), Compute a vector iinv s.t. iinv(ii) = ii(iinv) = 0...(n-1). For matrices, compute inverse permutations within columns.
Make an integer matrix of ones of the given dimensions.
Make an integer row vector from this call's vararg list.
Make an integer row vector from a List of Ints.
Make an integer row vector from an array of Ints.
Make an integer row vector from a 2-tuple.
Make an integer row vector from a 2-tuple. Supports the syntax 0->5 for ranges.
Make an integer row vector from a range.
Lexicographially sort with an index array, and return it.
Lexicographially sort with an index array, and return it. a is not modified
Lexicographially sort with an index array, and return it.
Lexicographially sort with an index array, and return it. a is not modified
Lexicographially sort with an index array, and return it.
Lexicographially sort with an index array, and return it. a is not modified
Lexicographially sort with an index array, and return it.
Lexicographially sort with an index array, and return it. a is not modified
Lexicographically sort some rows ascending, return only the indices
Lexicographically sort rows ascending
Lexicographially sort descending with an index array, and return it.
Lexicographially sort descending with an index array, and return it. a is not modified
Lexicographially sort descending with an index array, and return it.
Lexicographially sort descending with an index array, and return it. a is not modified
Lexicographically sort some rows descending, return only the indices
Lexicographic sort of a matrix mat with order asc (boolean true for ascending order).
Lexicographic sort of a matrix mat with order asc (boolean true for ascending order). Side-effects mat.
Make an integer matrix of zeros of the given dimensions.
Make an integer column vector from this calls vararg list.
Make an integer column vector from a List.
Make an integer column vector from a tuple to support 0->5 syntax for ranges.
Make an integer column vector from a range.
Return the length of a, (number of rows x columns)
Return the length of a, (number of rows x columns)
Return the length of a, (number of rows x columns)
Return the length of a, (number of rows x columns)
Make an integer matrix of ones of the given dimensions.
Make an integer row vector from this call's vararg list.
Make an long row vector from a List of Ints.
Make an integer row vector from an array of Ints.
Make an integer row vector from a 2-tuple.
Make an integer row vector from a 2-tuple. Supports the syntax 0->5 for ranges.
Make an integer row vector from a range.
Make an integer matrix of zeros of the given dimensions.
Creates a diagonal, square matrix with elements of a in the diagonal.
Creates a diagonal, square matrix with elements of a in the diagonal. Works on most matrix types.
Throws exception if a is a non-vector matrix.
Example, with IMats:
scala> val a = 1 on 2 on 3 a: BIDMat.IMat = 1 2 3 scala> mkdiag(a) res4: BIDMat.IMat = 1 0 0 0 2 0 0 0 3
Creates a diagonal, square GLMat matrix with elements of a in the diagonal.
Creates a diagonal, square GIMat matrix with elements of a in the diagonal.
Creates a diagonal, square GDMat matrix with elements of a in the diagonal.
Creates a diagonal, square GMat matrix with elements of a in the diagonal.
Creates a diagonal, square CMat matrix with elements of a in the diagonal.
Creates a diagonal, square LMat matrix with elements of a in the diagonal.
Creates a diagonal, square IMat matrix with elements of a in the diagonal.
Creates a diagonal, square FMat matrix with elements of a in the diagonal.
Creates a diagonal, square DMat matrix with elements of a in the diagonal.
Return the number of non-zeros in a
Return the number of non-zeros in a
Return the number of non-zeros in a
Return the number of non-zeros in a
Return the number of non-zeros in a
Return the number of non-zeros in a
Make a float matrix of ones of the given size.
implicit to convert ranges to IMats
Make a float row vector from a range.
Make a float row vector from varargs.
Make a float row vector from a List of generic type.
Make a float row vector from an array of Ints.
Make a float row vector from an array of doubles.
Make a float row matrix from an array of Floats.
Legacy function to make a placeholder matrix with no storage.
Legacy function to make a placeholder matrix with no storage.
Make a sparse double-precision matrix which is all zeros.
Retrieve the size of a along axis n - n=1: Number of rows - n=2: Number of columns
Return the size of a as a (rows, columns) tuple.
Sort a set of keys ascending.
Sort a set of key/ind pairs ascending.
Sort a set of keys ascending.
Sort a set of keys ascending along a given direction dir: 1=columns, 2=rows, 0=smart.
Sort a set of keys ascending.
Sort a set of key/ind pairs ascending.
Sort a set of keys ascending.
Sort a set of keys ascending along a given direction dir: 1=columns, 2=rows, 0=smart.
Sort a set of keys ascending.
Sort a set of key/ind pairs ascending.
Sort a set of keys ascending, and return sorted keys and indices.
Sort a set of keys and return sorted keys and indices along a given direction: 1=columns, 2=rows, 0=smart
Sort a set of keys ascending, and return sorted keys and indices.
Sort a set of keys and return sorted keys and indices along a given direction: 1=columns, 2=rows
Sort a set of keys ascending, and return sorted keys and indices.
Sort a set of keys and return sorted keys and indices along a given direction: 1=columns, 2=rows, 0=smart
Sort a set of keys ascending, and return sorted keys and indices.
Sort a set of keys and return sorted keys and indices along a given direction: 1=columns, 2=rows, 0=smart
Sort a set of keys ascending, and return sorted keys and indices.
Sort a set of key/ind pairs descending.
Sort a set of key/ind pairs descending.
Sort a set of keys descending.
Sort a set of keys descending along a given direction: 1=columns, 2=rows, 0=smart.
Sort a set of keys descending.
Sort a set of keys descending along a given direction: 1=columns, 2=rows.
Sort a set of keys descending.
Sort a set of keys descending along a given direction: 1=columns, 2=rows, 0=smart.
Sort a set of keys descending, and return sorted keys and indices.
Sort a set of key/ind pairs descending.
Sort a set of keys descending and return sorted keys and indices.
Sort a set of keys descending and return sorted keys and indices along a given direction: 1=columns, 2=rows, 0=smart
Sort a set of keys descending and return sorted keys and indices.
Sort a set of keys descending and return sorted keys and indices along a given direction: 1=columns, 2=rows
Sort a set of keys descending and return sorted keys and indices.
Sort a set of keys descending and return sorted keys and indices along a given direction: 1=columns, 2=rows, 0=smart
Sort a set of keys descending and return sorted keys and indices.
Sort a set of keys descending and return sorted keys and indices along a given direction: 1=columns, 2=rows, 0=smart
Sort a set of keys descending, and return sorted keys and indices.
Lexicographic sort of a matrix mat.
Lexicographic sort of a matrix mat. Side-effects mat.
Lexicographic sort of a matrix mat and a set of indices inds.
Lexicographic sort of a matrix mat and a set of indices inds. Side-effects both matrices, i.e. both mat and inds are modified.
Lexicographically sort rows ascending
Lexicographically sort some rows ascending
Lexicographically sort rows ascending
Lexicographically sort some rows ascending
Lexicographically sort rows descending
Lexicographically sort rows descending
Lexicographically sort rows descending
Lexicographically sort some rows descending
Construct an auto-sized sparse float matrix from arrays of indices (ii=row, jj=col) and values.
Construct a sparse float matrix from arrays of indices (ii=row, jj=col) and values, with given size.
Construct an auto-sized sparse double matrix from arrays of indices (ii=row, jj=col) and values.
Construct a sparse double matrix from arrays of indices (ii=row, jj=col) and values, with given size.
Convert a sparse double-precision sparse matrix to sparse.
Convert a dense double-precision sparse matrix to sparse.
Returns a sparse, diagonal n x n matrix with ones in the diagonal.
Returns a sparse, diagonal n x n matrix with ones in the diagonal.
Example:
scala> spdiag(3) res10: BIDMat.SMat = ( 0, 0) 1 ( 1, 1) 1 ( 2, 2) 1
Make an empty sparse matrix of ones of the given size.
Make a sparse single-precision matrix which is all zeros.
Establishes the start of a (seconds) timer, to be timed later at the next call to 'toc'.
Returns the elapsed time in milliseconds between now and the previous call to 'tic'.
implicit to convert 2-tuples to IMats over the range of the 2-tuple
Find unique elements.
Find unique elements. Return: (b,ii,jj) s.t. b=unique(a), b=a(ii,?), a=b(jj,?)
Find the unique rows from a matrix of input rows.
Find the unique rows from a matrix of input rows. Returns (outv, bptrs, outp) where
Find unique rows.
Find unique rows. Return: (b,ii,jj) s.t. b=uniquerows(a), b=a(ii,?), a=b(jj,?)
Make a float matrix of zeros of the given size.