Class SymmetricTrainer
- java.lang.Object
-
- java.lang.Thread
-
- org.deeplearning4j.parallelism.trainer.DefaultTrainer
-
- org.deeplearning4j.parallelism.trainer.SymmetricTrainer
-
- All Implemented Interfaces:
Runnable
,CommunicativeTrainer
,Trainer
public class SymmetricTrainer extends DefaultTrainer implements CommunicativeTrainer
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.deeplearning4j.parallelism.trainer.DefaultTrainer
DefaultTrainer.DefaultTrainerBuilder
-
Nested classes/interfaces inherited from class java.lang.Thread
Thread.State, Thread.UncaughtExceptionHandler
-
-
Field Summary
Fields Modifier and Type Field Description protected org.deeplearning4j.optimize.solvers.accumulation.GradientsAccumulator
accumulator
-
Fields inherited from class org.deeplearning4j.parallelism.trainer.DefaultTrainer
averagingFrequency, isStopped, lastEtlTime, modelLock, nullDataSet, nullMode, onRootModel, originalModel, parallelWrapper, queue, queueMDS, replicatedModel, running, shouldStop, shouldUpdate, threadId, thrownException, useMDS, uuid, workspaceMode
-
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
-
-
Constructor Summary
Constructors Constructor Description SymmetricTrainer(@NonNull org.deeplearning4j.nn.api.Model originalModel, String uuid, int threadIdx, @NonNull org.deeplearning4j.nn.conf.WorkspaceMode mode, @NonNull ParallelWrapper wrapper, boolean useMDS)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description boolean
averagingRequired()
This method returns TRUE if this Trainer implementation assumes periodic avervoid
enqueueGradient(org.deeplearning4j.optimize.listeners.SharedGradient gradient)
Deprecated.protected void
postInit()
This method does post-initialization configuration of Model.-
Methods inherited from class org.deeplearning4j.parallelism.trainer.DefaultTrainer
cloneListener, configureListeners, feedDataSet, feedMultiDataSet, fit, fit, getModel, isRunning, run, setupIfNeccessary, shutdown, updateModel, updateModelParams, updateUpdaterParams, waitTillRunning
-
Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, suspend, toString, yield
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.deeplearning4j.parallelism.trainer.Trainer
feedDataSet, feedMultiDataSet, getModel, getUuid, isRunning, setUncaughtExceptionHandler, shutdown, start, updateModel, updateModelParams, updateUpdaterParams, waitTillRunning
-
-
-
-
Constructor Detail
-
SymmetricTrainer
public SymmetricTrainer(@NonNull @NonNull org.deeplearning4j.nn.api.Model originalModel, String uuid, int threadIdx, @NonNull @NonNull org.deeplearning4j.nn.conf.WorkspaceMode mode, @NonNull @NonNull ParallelWrapper wrapper, boolean useMDS)
-
-
Method Detail
-
enqueueGradient
@Deprecated public void enqueueGradient(org.deeplearning4j.optimize.listeners.SharedGradient gradient)
Deprecated.- Specified by:
enqueueGradient
in interfaceCommunicativeTrainer
-
averagingRequired
public boolean averagingRequired()
Description copied from interface:Trainer
This method returns TRUE if this Trainer implementation assumes periodic aver- Specified by:
averagingRequired
in interfaceTrainer
- Overrides:
averagingRequired
in classDefaultTrainer
- Returns:
-
postInit
protected void postInit()
Description copied from class:DefaultTrainer
This method does post-initialization configuration of Model. Good place to configure listeners and all such a things- Overrides:
postInit
in classDefaultTrainer
-
-