接口 LossFunc

    • 方法概要

      所有方法 实例方法 抽象方法 
      修饰符和类型 方法 说明
      void computeGradient​(org.apache.flink.ml.common.feature.LabeledPointWithWeight dataPoint, org.apache.flink.ml.linalg.DenseVector coefficient, org.apache.flink.ml.linalg.DenseVector cumGradient)
      Computes the gradient on the given data point and adds the computed gradient to cumGradient.
      double computeLoss​(org.apache.flink.ml.common.feature.LabeledPointWithWeight dataPoint, org.apache.flink.ml.linalg.DenseVector coefficient)
      Computes the loss on the given data point.
    • 方法详细资料

      • computeLoss

        double computeLoss​(org.apache.flink.ml.common.feature.LabeledPointWithWeight dataPoint,
                           org.apache.flink.ml.linalg.DenseVector coefficient)
        Computes the loss on the given data point.
        参数:
        dataPoint - A training data point.
        coefficient - The model parameters.
        返回:
        The loss of the input data.
      • computeGradient

        void computeGradient​(org.apache.flink.ml.common.feature.LabeledPointWithWeight dataPoint,
                             org.apache.flink.ml.linalg.DenseVector coefficient,
                             org.apache.flink.ml.linalg.DenseVector cumGradient)
        Computes the gradient on the given data point and adds the computed gradient to cumGradient.
        参数:
        dataPoint - A training data point.
        coefficient - The model parameters.
        cumGradient - The accumulated gradient.