/** * Set the listeners, along with a StatsStorageRouter that the results will be shuffled to (in the case of any listeners * that implement the {@link RoutingIterationListener} interface) * * @param statsStorage Stats storage router to place the results into * @param listeners Listeners to set */ public void setListeners(StatsStorageRouter statsStorage, IterationListener... listeners) { setListeners(statsStorage, Arrays.asList(listeners)); }
/** * Set the listeners, along with a StatsStorageRouter that the results will be shuffled to (in the case of any listeners * that implement the {@link RoutingIterationListener} interface) * * @param statsStorage Stats storage router to place the results into * @param listeners Listeners to set */ public void setListeners(StatsStorageRouter statsStorage, IterationListener... listeners) { setListeners(statsStorage, Arrays.asList(listeners)); }
/** * This method allows you to specify IterationListeners for this model. * Note that for listeners like StatsListener (that have state that will be sent somewhere), consider instead * using {@link #setListeners(StatsStorageRouter, Collection)} * * @param listeners Listeners to set */ public void setListeners(@NonNull Collection<IterationListener> listeners) { setListeners(null, listeners); }
/** * This method allows you to specify IterationListeners for this model. * Note that for listeners like StatsListener (that have state that will be sent somewhere), consider instead * using {@link #setListeners(StatsStorageRouter, Collection)} * * @param listeners Listeners to set */ public void setListeners(@NonNull Collection<IterationListener> listeners) { setListeners(null, listeners); }
/** * This method allows you to specify IterationListeners for this model. * Note that for listeners like StatsListener (that have state that will be sent somewhere), consider instead * using {@link #setListeners(StatsStorageRouter, Collection)} * * @param listeners Listeners to set */ public void setListeners(@NonNull IterationListener... listeners) { setListeners(Arrays.asList(listeners)); }
/** * This method allows you to specify IterationListeners for this model. * Note that for listeners like StatsListener (that have state that will be sent somewhere), consider instead * using {@link #setListeners(StatsStorageRouter, Collection)} * * @param listeners Listeners to set */ public void setListeners(@NonNull IterationListener... listeners) { setListeners(Arrays.asList(listeners)); }
public ParallelTrainerOnGPU(ComputationGraph graph, int miniBatchSize, int totalExamplesPerIterator) { String numWorkersString = System.getProperty("framework.parallelWrapper.numWorkers"); int numWorkers = numWorkersString != null ? Integer.parseInt(numWorkersString) : 4; String prefetchBufferString = System.getProperty("framework.parallelWrapper.prefetchBuffer"); int prefetchBuffer = prefetchBufferString != null ? Integer.parseInt(prefetchBufferString) : 12 * numWorkers; String averagingFrequencyString = System.getProperty("framework.parallelWrapper.averagingFrequency"); int averagingFrequency = averagingFrequencyString != null ? Integer.parseInt(averagingFrequencyString) : 3; wrapper = new ParallelWrapper.Builder<>(graph) .prefetchBuffer(prefetchBuffer) .workers(numWorkers) .averagingFrequency(averagingFrequency) .reportScoreAfterAveraging(false) // .useLegacyAveraging(true) .build(); wrapper.setListeners(perListener); this.numExamplesPerIterator = totalExamplesPerIterator; this.miniBatchSize = miniBatchSize; }
wrapper.setListeners(modelListeners);
wrapper.setListeners(modelListeners);
wrapper.setListeners(remoteUIRouter, new StatsListener(null)); wrapper.setListeners(remoteUIRouter, new StatsListener(null));
wrapper.setListeners(remoteUIRouter, new StatsListener(null)); wrapper.setListeners(remoteUIRouter, new StatsListener(null));