def apply(self, dataset, can_fit=False):
        if self._batch_size is None:
            X = global_contrast_normalize(dataset.get_design_matrix(),
                                          scale=self._scale,
                                          subtract_mean=self._subtract_mean,
                                          use_std=self._use_std,
                                          sqrt_bias=self._sqrt_bias,
                                          min_divisor=self._min_divisor)
            dataset.set_design_matrix(X)
        else:
            data = dataset.get_design_matrix()
            data_size = data.shape[0]
            last = (numpy.floor(data_size / float(self._batch_size)) *
                    self._batch_size)
            for i in xrange(0, data_size, self._batch_size):
                stop = i + self._batch_size
                log.info("GCN processing data from %d to %d" % (i, stop))
                X = data[i:stop]
                X = global_contrast_normalize(
                    X,
                    scale=self._scale,
                    subtract_mean=self._subtract_mean,
                    use_std=self._use_std,
                    sqrt_bias=self._sqrt_bias,
                    min_divisor=self._min_divisor)
                dataset.set_design_matrix(X, start=i)
.. todo::
dataset/ETHPy150Open lisa-lab/pylearn2/pylearn2/datasets/preprocessing.py/GlobalContrastNormalization.apply