neupy.algorithms.step_update.errdiff module

class neupy.algorithms.step_update.errdiff.ErrDiffStepUpdate[source]

This algorithm make step update base on error difference between epochs.

Parameters:

update_for_smaller_error : float

Multiplies this option to step in if the error was less than in previous epochs. Defaults to 1.05. Value can’t be less than 1.

update_for_bigger_error : float

Multiplies this option to step in if the error was more than in previous epochs. Defaults to 0.7.

error_difference : float

The value indicates how many had to increase the error from the previous epochs that would produce reduction step. Defaults to 1.04. Value can’t be less than 1.

Warns:

It works only with algorithms based on backpropagation.

Examples

>>> from neupy import algorithms
>>>
>>> bpnet = algorithms.GradientDescent(
...     (2, 4, 1),
...     step=0.1,
...     verbose=False,
...     addons=[algorithms.ErrDiffStepUpdate]
... )
error_difference = None[source]
init_train_updates()[source]
init_variables()[source]
on_epoch_start_update(epoch)[source]
options = {'update_for_smaller_error': Option(class_name='ErrDiffStepUpdate', value=BoundedProperty(name="update_for_smaller_error")), 'update_for_bigger_error': Option(class_name='ErrDiffStepUpdate', value=ProperFractionProperty(name="update_for_bigger_error")), 'error_difference': Option(class_name='ErrDiffStepUpdate', value=BoundedProperty(name="error_difference"))}[source]
update_for_bigger_error = None[source]
update_for_smaller_error = None[source]