public class LogisticRule extends NeuronUpdateRule implements BoundedUpdateRule, ClippableUpdateRule, ActivityGenerator
NeuronUpdateRule.InputType
Modifier and Type | Field and Description |
---|---|
static double |
DEFAULT_FLOOR |
DEFAULT_INCREMENT, increment, inputType
Constructor and Description |
---|
LogisticRule() |
LogisticRule(LogisticRule lr,
Neuron n) |
Modifier and Type | Method and Description |
---|---|
double |
clip(double val)
Clip the current activation.
|
LogisticRule |
deepCopy()
Returns a deep copy of the update rule.
|
java.lang.String |
getDescription()
Returns a brief description of this update rule.
|
double |
getGrowthRate() |
double |
getLowerBound()
Returns the lower bound.
|
Network.TimeType |
getTimeType()
Returns the type of time update (discrete or continuous) associated with
this neuron.
|
double |
getUpperBound()
Returns the upper bound.
|
void |
init(Neuron neuron)
TODO: Doesn't feel like good API...
|
boolean |
isClipped()
Is clipping turned on or not.
|
void |
setClipped(boolean clipping)
Turn clipping on and off.
|
void |
setGrowthRate(double growthRate) |
void |
setLowerBound(double floor)
Sets the lower bound of this neuron update rule's activation.
|
void |
setUpperBound(double ceiling)
Sets the upper bound of this neuron update rule's activation.
|
void |
update(Neuron neuron)
Apply the update rule.
|
clear, contextualDecrement, contextualIncrement, decrementActivation, getDefaultIncrement, getGraphicalLowerBound, getGraphicalUpperBound, getIncrement, getInputType, getRandomValue, getToolTipText, incrementActivation, isSkipsSynapticUpdates, isSpikingNeuron, setIncrement, setInputType
public static final double DEFAULT_FLOOR
public LogisticRule(LogisticRule lr, Neuron n)
public LogisticRule()
public Network.TimeType getTimeType()
getTimeType
in class NeuronUpdateRule
public void init(Neuron neuron)
init
in interface ActivityGenerator
public LogisticRule deepCopy()
init
must be called to
ensure rational behavior for an activity generator. The
copy
constructor
is the preferred method of copying because
init
is called on the neuron parameter
automatically.deepCopy
in class NeuronUpdateRule
public void update(Neuron neuron)
update
in class NeuronUpdateRule
neuron
- public double getGrowthRate()
public void setGrowthRate(double growthRate)
growthRate
- The growthRate to set.public java.lang.String getDescription()
NeuronUpdateRule
getDescription
in class NeuronUpdateRule
public double clip(double val)
ClippableUpdateRule
clip
in interface ClippableUpdateRule
val
- the value to clippublic boolean isClipped()
ClippableUpdateRule
isClipped
in interface ClippableUpdateRule
public void setClipped(boolean clipping)
ClippableUpdateRule
setClipped
in interface ClippableUpdateRule
clipping
- true if clipping should be on; false otherwisepublic void setUpperBound(double ceiling)
BoundedUpdateRule
setUpperBound
in interface BoundedUpdateRule
ceiling
- the upper boundpublic void setLowerBound(double floor)
BoundedUpdateRule
setLowerBound
in interface BoundedUpdateRule
floor
- the lower boundpublic double getUpperBound()
BoundedUpdateRule
getUpperBound
in interface BoundedUpdateRule
public double getLowerBound()
BoundedUpdateRule
getLowerBound
in interface BoundedUpdateRule