public abstract class AComponent extends Object implements IComponent
| Constructor and Description |
|---|
AComponent() |
| Modifier and Type | Method and Description |
|---|---|
void |
applyConstraints() |
abstract AComponent |
clone()
Creates a clone of a module, including a deep copy of any mutable state.
|
mikera.vectorz.AVector |
generate(mikera.vectorz.AVector output) |
void |
generate(mikera.vectorz.AVector input,
mikera.vectorz.AVector output) |
IComponent |
getComponent(int i) |
int |
getInputLength() |
IInputState |
getInputState() |
List<IModule> |
getModules()
Returns a list of sub-components of this module
|
int |
getOutputLength() |
int |
getParameterLength()
Returns the length of the parameter vector for this model
|
boolean |
isStochastic() |
void |
setInput(mikera.vectorz.AVector inputValues) |
void |
setOutput(mikera.vectorz.AVector outputValues) |
mikera.vectorz.AVector |
think(mikera.vectorz.AVector input) |
void |
think(mikera.vectorz.AVector input,
mikera.vectorz.AVector output) |
void |
thinkInternalTraining()
Thinks within the scope of the component.
|
IComponent |
topComponent() |
void |
train(mikera.vectorz.AVector input,
mikera.vectorz.AVector target) |
void |
train(mikera.vectorz.AVector input,
mikera.vectorz.AVector target,
LossFunction loss,
double factor) |
void |
trainGradient(mikera.vectorz.AVector gradient,
double factor)
Trains with a output gradient, incrementing inputGradient and
accumulated gradient for parameters.
|
abstract void |
trainGradientInternal(double factor) |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetComponents, thinkInternalgetGradient, getParametersgetInput, getInputGradientgetOutput, getOutputGradientpublic IComponent topComponent()
public void think(mikera.vectorz.AVector input,
mikera.vectorz.AVector output)
public void thinkInternalTraining()
IComponentthinkInternalTraining in interface IComponentthinkInternalTraining in interface ITrainablepublic mikera.vectorz.AVector think(mikera.vectorz.AVector input)
public mikera.vectorz.AVector generate(mikera.vectorz.AVector output)
public void generate(mikera.vectorz.AVector input,
mikera.vectorz.AVector output)
public void train(mikera.vectorz.AVector input,
mikera.vectorz.AVector target)
train in interface ITrainablepublic void train(mikera.vectorz.AVector input,
mikera.vectorz.AVector target,
LossFunction loss,
double factor)
train in interface ITrainablepublic void trainGradient(mikera.vectorz.AVector gradient,
double factor)
IGradientTrainabletrainGradient in interface IGradientTrainablefactor - TODOpublic abstract void trainGradientInternal(double factor)
trainGradientInternal in interface IComponentpublic void setInput(mikera.vectorz.AVector inputValues)
setInput in interface IInputStatepublic void setOutput(mikera.vectorz.AVector outputValues)
setOutput in interface IOutputStatepublic int getParameterLength()
IParameterisedgetParameterLength in interface IParameterisedpublic IComponent getComponent(int i)
public List<IModule> getModules()
IModulegetModules in interface IModulepublic IInputState getInputState()
getInputState in interface IComponentpublic int getInputLength()
getInputLength in interface IInputpublic int getOutputLength()
getOutputLength in interface IOutputpublic boolean isStochastic()
isStochastic in interface IComponentpublic void applyConstraints()
applyConstraints in interface IComponentpublic abstract AComponent clone()
IModuleclone in interface IComponentclone in interface IModuleclone in interface IParameterisedclone in interface IThinkerclone in interface ITrainableclone in class ObjectCopyright © 2013. All Rights Reserved.