org.apache.spark.mllib.linalg.distributed

BlockMatrix

class BlockMatrix extends DistributedMatrix with Logging

:: Experimental ::

Represents a distributed matrix in blocks of local matrices.

Annotations
@Since( "1.3.0" ) @Experimental()
Linear Supertypes
Logging, DistributedMatrix, Serializable, Serializable, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. BlockMatrix
  2. Logging
  3. DistributedMatrix
  4. Serializable
  5. Serializable
  6. AnyRef
  7. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new BlockMatrix(blocks: RDD[((Int, Int), Matrix)], rowsPerBlock: Int, colsPerBlock: Int)

    Alternate constructor for BlockMatrix without the input of the number of rows and columns.

    Alternate constructor for BlockMatrix without the input of the number of rows and columns.

    blocks

    The RDD of sub-matrix blocks ((blockRowIndex, blockColIndex), sub-matrix) that form this distributed matrix. If multiple blocks with the same index exist, the results for operations like add and multiply will be unpredictable.

    rowsPerBlock

    Number of rows that make up each block. The blocks forming the final rows are not required to have the given number of rows

    colsPerBlock

    Number of columns that make up each block. The blocks forming the final columns are not required to have the given number of columns

    Annotations
    @Since( "1.3.0" )
  2. new BlockMatrix(blocks: RDD[((Int, Int), Matrix)], rowsPerBlock: Int, colsPerBlock: Int, nRows: Long, nCols: Long)

    blocks

    The RDD of sub-matrix blocks ((blockRowIndex, blockColIndex), sub-matrix) that form this distributed matrix. If multiple blocks with the same index exist, the results for operations like add and multiply will be unpredictable.

    rowsPerBlock

    Number of rows that make up each block. The blocks forming the final rows are not required to have the given number of rows

    colsPerBlock

    Number of columns that make up each block. The blocks forming the final columns are not required to have the given number of columns

    nRows

    Number of rows of this matrix. If the supplied value is less than or equal to zero, the number of rows will be calculated when numRows is invoked.

    nCols

    Number of columns of this matrix. If the supplied value is less than or equal to zero, the number of columns will be calculated when numCols is invoked.

    Annotations
    @Since( "1.3.0" )

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. def add(other: BlockMatrix): BlockMatrix

    Adds two block matrices together.

    Adds two block matrices together. The matrices must have the same size and matching rowsPerBlock and colsPerBlock values. If one of the blocks that are being added are instances of SparseMatrix, the resulting sub matrix will also be a SparseMatrix, even if it is being added to a DenseMatrix. If two dense matrices are added, the output will also be a DenseMatrix.

    Annotations
    @Since( "1.3.0" )
  7. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  8. val blocks: RDD[((Int, Int), Matrix)]

    The RDD of sub-matrix blocks ((blockRowIndex, blockColIndex), sub-matrix) that form this distributed matrix.

    The RDD of sub-matrix blocks ((blockRowIndex, blockColIndex), sub-matrix) that form this distributed matrix. If multiple blocks with the same index exist, the results for operations like add and multiply will be unpredictable.

    Annotations
    @Since( "1.3.0" )
  9. def cache(): BlockMatrix.this.type

    Caches the underlying RDD.

    Caches the underlying RDD.

    Annotations
    @Since( "1.3.0" )
  10. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  11. val colsPerBlock: Int

    Number of columns that make up each block.

    Number of columns that make up each block. The blocks forming the final columns are not required to have the given number of columns

    Annotations
    @Since( "1.3.0" )
  12. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  13. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  14. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  15. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  16. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  17. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  18. def isTraceEnabled(): Boolean

    Attributes
    protected
    Definition Classes
    Logging
  19. def log: Logger

    Attributes
    protected
    Definition Classes
    Logging
  20. def logDebug(msg: ⇒ String, throwable: Throwable): Unit

    Attributes
    protected
    Definition Classes
    Logging
  21. def logDebug(msg: ⇒ String): Unit

    Attributes
    protected
    Definition Classes
    Logging
  22. def logError(msg: ⇒ String, throwable: Throwable): Unit

    Attributes
    protected
    Definition Classes
    Logging
  23. def logError(msg: ⇒ String): Unit

    Attributes
    protected
    Definition Classes
    Logging
  24. def logInfo(msg: ⇒ String, throwable: Throwable): Unit

    Attributes
    protected
    Definition Classes
    Logging
  25. def logInfo(msg: ⇒ String): Unit

    Attributes
    protected
    Definition Classes
    Logging
  26. def logName: String

    Attributes
    protected
    Definition Classes
    Logging
  27. def logTrace(msg: ⇒ String, throwable: Throwable): Unit

    Attributes
    protected
    Definition Classes
    Logging
  28. def logTrace(msg: ⇒ String): Unit

    Attributes
    protected
    Definition Classes
    Logging
  29. def logWarning(msg: ⇒ String, throwable: Throwable): Unit

    Attributes
    protected
    Definition Classes
    Logging
  30. def logWarning(msg: ⇒ String): Unit

    Attributes
    protected
    Definition Classes
    Logging
  31. def multiply(other: BlockMatrix): BlockMatrix

    Left multiplies this BlockMatrix to other, another BlockMatrix.

    Left multiplies this BlockMatrix to other, another BlockMatrix. The colsPerBlock of this matrix must equal the rowsPerBlock of other. If other contains SparseMatrix, they will have to be converted to a DenseMatrix. The output BlockMatrix will only consist of blocks of DenseMatrix. This may cause some performance issues until support for multiplying two sparse matrices is added.

    Annotations
    @Since( "1.3.0" )
  32. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  33. final def notify(): Unit

    Definition Classes
    AnyRef
  34. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  35. val numColBlocks: Int

    Annotations
    @Since( "1.3.0" )
  36. def numCols(): Long

    Gets or computes the number of columns.

    Gets or computes the number of columns.

    Definition Classes
    BlockMatrixDistributedMatrix
    Annotations
    @Since( "1.3.0" )
  37. val numRowBlocks: Int

    Annotations
    @Since( "1.3.0" )
  38. def numRows(): Long

    Gets or computes the number of rows.

    Gets or computes the number of rows.

    Definition Classes
    BlockMatrixDistributedMatrix
    Annotations
    @Since( "1.3.0" )
  39. def persist(storageLevel: StorageLevel): BlockMatrix.this.type

    Persists the underlying RDD with the specified storage level.

    Persists the underlying RDD with the specified storage level.

    Annotations
    @Since( "1.3.0" )
  40. val rowsPerBlock: Int

    Number of rows that make up each block.

    Number of rows that make up each block. The blocks forming the final rows are not required to have the given number of rows

    Annotations
    @Since( "1.3.0" )
  41. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  42. def toCoordinateMatrix(): CoordinateMatrix

    Converts to CoordinateMatrix.

    Converts to CoordinateMatrix.

    Annotations
    @Since( "1.3.0" )
  43. def toIndexedRowMatrix(): IndexedRowMatrix

    Converts to IndexedRowMatrix.

    Converts to IndexedRowMatrix. The number of columns must be within the integer range.

    Annotations
    @Since( "1.3.0" )
  44. def toLocalMatrix(): Matrix

    Collect the distributed matrix on the driver as a DenseMatrix.

    Collect the distributed matrix on the driver as a DenseMatrix.

    Annotations
    @Since( "1.3.0" )
  45. def toString(): String

    Definition Classes
    AnyRef → Any
  46. def transpose: BlockMatrix

    Transpose this BlockMatrix.

    Transpose this BlockMatrix. Returns a new BlockMatrix instance sharing the same underlying data. Is a lazy operation.

    Annotations
    @Since( "1.3.0" )
  47. def validate(): Unit

    Validates the block matrix info against the matrix data (blocks) and throws an exception if any error is found.

    Validates the block matrix info against the matrix data (blocks) and throws an exception if any error is found.

    Annotations
    @Since( "1.3.0" )
  48. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  49. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  50. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Logging

Inherited from DistributedMatrix

Inherited from Serializable

Inherited from Serializable

Inherited from AnyRef

Inherited from Any

Ungrouped