Package org.nd4j.linalg.learning
Interface GradientUpdater<T extends IUpdater>
-
- All Known Implementing Classes:
AdaBeliefUpdater,AdaDeltaUpdater,AdaGradUpdater,AdaMaxUpdater,AdamUpdater,AMSGradUpdater,NadamUpdater,NesterovsUpdater,NoOpUpdater,RmsPropUpdater,SgdUpdater
public interface GradientUpdater<T extends IUpdater>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidapplyUpdater(INDArray gradient, int iteration, int epoch)Modify the gradient to be an update.TgetConfig()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.
-
-
-
Method Detail
-
getConfig
T getConfig()
-
setStateViewArray
void setStateViewArray(INDArray viewArray, long[] gradientShape, char gradientOrder, boolean initialize)
For 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)- Parameters:
viewArray- Array (that is a view of a larger array) to use for the state.gradientShape-gradientOrder-initialize- If true: the updater must initialize the view array. If false: no change to view array contents
-
applyUpdater
void applyUpdater(INDArray gradient, int iteration, int epoch)
Modify the gradient to be an update. Note that this is be done in-place- Parameters:
gradient- the gradient to modifyiteration-
-
-