public abstract class Solver extends Object implements scala.Serializable, WithParameters
Modifier and Type | Class and Description |
---|---|
static class |
Solver.LossFunction$ |
static class |
Solver.RegularizationConstant$ |
Constructor and Description |
---|
Solver() |
Modifier and Type | Method and Description |
---|---|
DataSet<WeightVector> |
createInitialWeightsDS(scala.Option<DataSet<WeightVector>> initialWeights,
DataSet<LabeledVector> data)
Creates initial weights vector, creating a DataSet with a WeightVector element
|
DataSet<WeightVector> |
createInitialWeightVector(DataSet<Object> dimensionDS)
Creates a DataSet with one zero vector.
|
abstract DataSet<WeightVector> |
optimize(DataSet<LabeledVector> data,
scala.Option<DataSet<WeightVector>> initialWeights)
Provides a solution for the given optimization problem
|
Solver |
setLossFunction(LossFunction lossFunction) |
Solver |
setRegularizationConstant(double regularizationConstant) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
parameters
public abstract DataSet<WeightVector> optimize(DataSet<LabeledVector> data, scala.Option<DataSet<WeightVector>> initialWeights)
data
- A Dataset of LabeledVector (input, output) pairsinitialWeights
- The initial weight that will be optimizedpublic DataSet<WeightVector> createInitialWeightsDS(scala.Option<DataSet<WeightVector>> initialWeights, DataSet<LabeledVector> data)
initialWeights
- An Option that may contain an initial set of weightsdata
- The data for which we optimize the weightspublic DataSet<WeightVector> createInitialWeightVector(DataSet<Object> dimensionDS)
dimensionDS
- DataSet with one element d, denoting the dimension of the returned zero
vectorpublic Solver setLossFunction(LossFunction lossFunction)
public Solver setRegularizationConstant(double regularizationConstant)
Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.