Enum Class MatrixFormat

java.lang.Object
java.lang.Enum<MatrixFormat>
org.apache.sysds.api.mlcontext.MatrixFormat
All Implemented Interfaces:
Serializable, Comparable<MatrixFormat>, Constable

public enum MatrixFormat extends Enum<MatrixFormat>
MatrixFormat represents the different matrix formats supported by the MLContext API.
  • Enum Constant Details

    • CSV

      public static final MatrixFormat CSV
      Comma-separated value format (dense).
    • IJV

      public static final MatrixFormat IJV
      (I J V) format (sparse). I and J represent matrix coordinates and V represents the value. The I J and V values are space-separated.
    • DF_DOUBLES_WITH_INDEX

      public static final MatrixFormat DF_DOUBLES_WITH_INDEX
      DataFrame of doubles with a row index.
    • DF_DOUBLES

      public static final MatrixFormat DF_DOUBLES
      DataFrame of doubles with no row index.
    • DF_VECTOR_WITH_INDEX

      public static final MatrixFormat DF_VECTOR_WITH_INDEX
      Vector DataFrame with a row index.
    • DF_VECTOR

      public static final MatrixFormat DF_VECTOR
      Vector DataFrame with no row index.
  • Method Details

    • values

      public static MatrixFormat[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static MatrixFormat valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • isVectorBased

      public boolean isVectorBased()
      Is the matrix format vector-based?
      Returns:
      true if matrix is a vector-based DataFrame, false otherwise.
    • hasIDColumn

      public boolean hasIDColumn()
      Does the DataFrame have a row index?
      Returns:
      true if the DataFrame has a row index, false otherwise.