org.apache.sysds.runtime.instructions.cp

## Class KahanObject

- java.lang.Object
- - org.apache.sysds.runtime.instructions.cp.Data
  - - org.apache.sysds.runtime.instructions.cp.KahanObject

- All Implemented Interfaces:
    Serializable

      public class KahanObject
      extends Data

  See Also:
    Serialized Form

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `double` | `_correction`
    `double` | `_sum`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `KahanObject(double sum, double cor)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static int` | `compare(KahanObject k1, KahanObject k2)`
    `boolean` | `equals(Object o)`
    `String` | `getDebugName()`
    `int` | `hashCode()`
    `boolean` | `isAllZero()`
    `void` | `read(DataInput in)`
    `void` | `set(double s, double c)`
    `void` | `set(KahanObject that)`
    `String` | `toString()`
    `void` | `write(DataOutput out)`

    - ### Methods inherited from class org.apache.sysds.runtime.instructions.cp.Data

      `getDataType, getMetaData, getPrivacyConstraint, getValueType, removeMetaData, setMetaData, setPrivacyConstraints, updateDataCharacteristics`

    - ### Methods inherited from class java.lang.Object

      `getClass, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### _sum

          public double _sum

    - #### _correction

          public double _correction

  - ### Constructor Detail

    - #### KahanObject

          public KahanObject(double sum,
                             double cor)

  - ### Method Detail

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

    - #### compare

          public static int compare(KahanObject k1,
                                    KahanObject k2)

    - #### equals

          public boolean equals(Object o)

      Overrides:
        `equals` in class `Object`

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### read

          public void read(DataInput in)
                    throws IOException

      Throws:
        `IOException`

    - #### write

          public void write(DataOutput out)
                     throws IOException

      Throws:
        `IOException`

    - #### set

          public void set(KahanObject that)

    - #### set

          public void set(double s,
                          double c)

    - #### isAllZero

          public boolean isAllZero()

    - #### getDebugName

          public String getDebugName()

      Specified by:
        `getDebugName` in class `Data`

Copyright © 2020 The Apache Software Foundation. All rights reserved.