'Validate input params.'

def _validate_params(self):

    if (not isinstance(self.shuffle, bool)):
        raise ValueError('shuffle    must    be    either    True    or    False')
    if (self.max_iter <= 0):
        raise ValueError(('max_iter    must    be    >    zero.    Got    %f' % self.max_iter))
    if (not (0.0 <= self.l1_ratio <= 1.0)):
        raise ValueError('l1_ratio    must    be    in    [0,    1]')
    if (self.alpha < 0.0):
        raise ValueError('alpha    must    be    >=    0')
    if (self.learning_rate in ('constant', 'invscaling')):
        if (self.eta0 <= 0.0):
            raise ValueError('eta0    must    be    >    0')
    if ((self.learning_rate == 'optimal') and (self.alpha == 0)):
        raise ValueError("alpha    must    be    >    0    since    learning_rate    is    'optimal'.    alpha    is    used    to    compute    the    optimal    learning    rate.")
    self._get_penalty_type(self.penalty)
    self._get_learning_rate_type(self.learning_rate)
    if (self.loss not in self.loss_functions):
        raise ValueError(('The    loss    %s    is    not    supported.    ' % self.loss))
