':param max_epochs:
:param tolerance:
:param update_method:
:param batch_size: None or an integer. If None the whole dataset will be used.
:param callback:
:param kwargs:
:return:'

def __init__(self, update_method=lasagne.updates.adam, learning_rate=0.001, max_epochs=1000, tolerance=1e-06, batch_size=32, callback=None, verbose=False, **kwargs):

    Serializable.quick_init(self, locals())
    self._opt_fun = None
    self._target = None
    self._callback = callback
    update_method = partial(update_method, learning_rate=learning_rate)
    self._update_method = update_method
    self._max_epochs = max_epochs
    self._tolerance = tolerance
    self._batch_size = batch_size
    self._verbose = verbose
