Package org.nd4j.linalg.learning
Class AdaDeltaUpdater
- java.lang.Object
-
- org.nd4j.linalg.learning.AdaDeltaUpdater
-
- All Implemented Interfaces:
GradientUpdater<AdaDelta>
public class AdaDeltaUpdater extends Object implements GradientUpdater<AdaDelta>
-
-
Field Summary
Fields Modifier and Type Field Description static StringMSDX_STATEstatic StringMSG_STATE
-
Constructor Summary
Constructors Constructor Description AdaDeltaUpdater(AdaDelta config)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidapplyUpdater(INDArray gradient, int iteration, int epoch)Get the updated gradient for the given gradient and also update the state of ada delta.Map<String,INDArray>getState()voidsetState(Map<String,INDArray> stateMap, boolean initialize)voidsetStateViewArray(INDArray viewArray, long[] gradientShape, char gradientOrder, boolean initialize)For the internal updater state (if any): set this to use the provided array.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.nd4j.linalg.learning.GradientUpdater
getConfig
-
-
-
-
Field Detail
-
MSG_STATE
public static final String MSG_STATE
- See Also:
- Constant Field Values
-
MSDX_STATE
public static final String MSDX_STATE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
AdaDeltaUpdater
public AdaDeltaUpdater(AdaDelta config)
-
-
Method Detail
-
setState
public void setState(Map<String,INDArray> stateMap, boolean initialize)
- Specified by:
setStatein interfaceGradientUpdater<AdaDelta>
-
getState
public Map<String,INDArray> getState()
- Specified by:
getStatein interfaceGradientUpdater<AdaDelta>
-
setStateViewArray
public void setStateViewArray(INDArray viewArray, long[] gradientShape, char gradientOrder, boolean initialize)
Description copied from interface:GradientUpdaterFor the internal updater state (if any): set this to use the provided array. Used during initialization, and when restoring the updater state (after serialization, for example)- Specified by:
setStateViewArrayin interfaceGradientUpdater<AdaDelta>- Parameters:
viewArray- Array (that is a view of a larger array) to use for the state.initialize- If true: the updater must initialize the view array. If false: no change to view array contents
-
applyUpdater
public void applyUpdater(INDArray gradient, int iteration, int epoch)
Get the updated gradient for the given gradient and also update the state of ada delta.- Specified by:
applyUpdaterin interfaceGradientUpdater<AdaDelta>- Parameters:
gradient- the gradient to get the updated gradient foriteration-
-
-