pyspark.ml.linalg.
DenseMatrix
(numRows: int, numCols: int, values: Union[bytes, Iterable[float]], isTransposed: bool = False)¶
Column-major dense matrix.
Methods
toArray
()
Return a numpy.ndarray
toSparse
()
Convert to SparseMatrix
Methods Documentation
toArray
() → numpy.ndarray¶
Return a numpy.ndarray
Examples
>>> m = DenseMatrix(2, 2, range(4)) >>> m.toArray() array([[ 0., 2.], [ 1., 3.]])
toSparse
() → pyspark.ml.linalg.SparseMatrix¶
Convert to SparseMatrix
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4