(value, n)
return value
Go through various types of hyperparameters.
Go through various types of hyperparameters.
Go through various types of hyperparameters .
def setup(value, n):
    """ Go through various types of hyperparameters. """
    if not isinstance(value, list):
        try:
            return [value.copy() for _ in range(n)]
        except AttributeError:
            return [value for _ in range(n)]
    assert len(value) == n, \
            'Number of elements must match number of conditions or 1.'
    return value
def setup ( value , n ) : if not isinstance ( value , list ) : try : return [ value . copy ( ) for _ in range ( n ) ] except AttributeError : return [ value for _ in range ( n ) ] assert len ( value ) == n , 'Number of elements must match number of conditions or 1.' return value