public class SGDObjectiveTerm extends Object implements ReasonerTerm
Constructor and Description |
---|
SGDObjectiveTerm(VariableTermStore<SGDObjectiveTerm,RandomVariableAtom> termStore,
boolean squared,
boolean hinge,
Hyperplane<RandomVariableAtom> hyperplane,
float weight,
float learningRate) |
Modifier and Type | Method and Description |
---|---|
float |
evaluate(float[] variableValues) |
int |
fixedByteSize()
The number of bytes that writeFixedValues() will need to represent this term.
|
void |
minimize(int iteration,
float[] variableValues) |
void |
read(ByteBuffer fixedBuffer,
ByteBuffer volatileBuffer)
Assume the term that will be next read from the buffers.
|
int |
size() |
String |
toString() |
void |
writeFixedValues(ByteBuffer fixedBuffer)
Write a binary representation of the fixed values of this term to a buffer.
|
public SGDObjectiveTerm(VariableTermStore<SGDObjectiveTerm,RandomVariableAtom> termStore, boolean squared, boolean hinge, Hyperplane<RandomVariableAtom> hyperplane, float weight, float learningRate)
public int size()
size
in interface ReasonerTerm
public float evaluate(float[] variableValues)
public void minimize(int iteration, float[] variableValues)
public int fixedByteSize()
public void writeFixedValues(ByteBuffer fixedBuffer)
public void read(ByteBuffer fixedBuffer, ByteBuffer volatileBuffer)
Copyright © 2020 University of California, Santa Cruz. All rights reserved.