|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectfunction.BasicVectorFunction
caffeinterface.CaffeToVectorFunction
public abstract class CaffeToVectorFunction
Provides functionality similar to CaffeToScalarFunction, but for the
case where there are multiple outputs computed by CAFFE.
| Field Summary | |
|---|---|
protected caffe.SharedData |
db
|
| Fields inherited from class function.BasicVectorFunction |
|---|
DEFAULT_BOUNDS, DEFAULT_INPUT_DIMENSION, DEFAULT_OUTPUT_DIMENSION, VALUE_OUTSIDE_BOUNDS |
| Constructor Summary | |
|---|---|
CaffeToVectorFunction()
|
|
| Method Summary | |
|---|---|
caffe.CaffeClass |
getMainClass()
Returns the main compute class in the CAFFE application. |
java.lang.String |
getXmlFileName()
Returns the name of the XML file to be used for data input. |
void |
init()
Initialization method. |
boolean |
isClientServerMode()
Returns the clientServerMode. |
boolean |
isWithinBounds(double[] x)
Returns true if the given point is within bounds. |
protected abstract void |
populateDatabase(double[] x)
Populates the CAFFE database with variable values based on the given vector x. |
void |
quickCompute(double[] x,
double[] y)
Abstract method that all subclasses must implement. |
void |
quickCompute(cern.colt.matrix.DoubleMatrix2D X,
cern.colt.matrix.DoubleMatrix2D Y)
Applies BasicVectorFunction.compute(double[]) on a set of inputs, supplied row-wise in
a matrix. |
protected abstract void |
readResults(double[] y)
Reads the results from the database and suitably populates the given output array y. |
void |
setClientServerMode(boolean clientServerMode)
Sets the clientServerMode. |
void |
setXmlFileName(java.lang.String xmlFileName)
Sets the name of the XML file to be used for data input |
| Methods inherited from class function.BasicVectorFunction |
|---|
checkInputDimension, compute, compute, compute, compute, compute, getBounds, getInputDimension, getOutputDimension, makeBounds |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected caffe.SharedData db
| Constructor Detail |
|---|
public CaffeToVectorFunction()
| Method Detail |
|---|
public caffe.CaffeClass getMainClass()
public java.lang.String getXmlFileName()
public void init()
BasicVectorFunction
init in interface VectorFunctioninit in class BasicVectorFunctionpublic boolean isClientServerMode()
public boolean isWithinBounds(double[] x)
Computabletrue if the given point is within bounds.
isWithinBounds in interface ComputableisWithinBounds in class BasicVectorFunctionx - the given point.
true if within bounds.
public void quickCompute(double[] x,
double[] y)
BasicVectorFunctiondouble array and returns an
output double array.
quickCompute in interface VectorFunctionquickCompute in class BasicVectorFunctionx - input array.y - output array.
public void quickCompute(cern.colt.matrix.DoubleMatrix2D X,
cern.colt.matrix.DoubleMatrix2D Y)
BasicVectorFunctionBasicVectorFunction.compute(double[]) on a set of inputs, supplied row-wise in
a matrix. Stores the result in the supplied output array. No size-checking
is performed.
quickCompute in interface VectorFunctionquickCompute in class BasicVectorFunctionX - input matrix.Y - output matrix.public void setClientServerMode(boolean clientServerMode)
clientServerMode - the given clientServerMode.public void setXmlFileName(java.lang.String xmlFileName)
xmlFileName - the name of the XML file for data input.protected abstract void populateDatabase(double[] x)
Computable to the variables in the CAFFE database.
x - the given set of design values.protected abstract void readResults(double[] y)
y - the given output array.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||