def __init__(self, reduce='half_squared_sum'):
    self.h_centered = None
    self.covariance = None
    if (reduce not in ('half_squared_sum', 'no')):
        raise ValueError(("only 'half_squared_sum' and 'no' are valid for 'reduce', but '%s' is given" % reduce))
    self.reduce = reduce
def __init__(self, reduce='half_squared_sum'):
    self.h_centered = None
    self.covariance = None
    if (reduce not in ('half_squared_sum', 'no')):
        raise ValueError(("only 'half_squared_sum' and 'no' are valid for 'reduce', but '%s' is given" % reduce))
    self.reduce = reduce