jettify / pytorch-optimizer

Line too long FLK-E501
Style
Minor
5 occurrences in this check
line too long (90 > 88 characters)
10    Example:
11    >>> import test_functions
12    >>> rastrigin = test_functions.Rastrigin()
13    >>> x = torch.linspace(rastrigin.x_domain[0], rastrigin.x_domain[1], rastrigin.num_pt)14    >>> y = torch.linspace(rastrigin.y_domain[0], rastrigin.y_domain[1], rastrigin.num_pt)
15    >>> Y, X = torch.meshgrid(x, y)
16    >>> Z = rastrigin([X, Y])
line too long (90 > 88 characters)
11    >>> import test_functions
12    >>> rastrigin = test_functions.Rastrigin()
13    >>> x = torch.linspace(rastrigin.x_domain[0], rastrigin.x_domain[1], rastrigin.num_pt)
14    >>> y = torch.linspace(rastrigin.y_domain[0], rastrigin.y_domain[1], rastrigin.num_pt)15    >>> Y, X = torch.meshgrid(x, y)
16    >>> Z = rastrigin([X, Y])
17
line too long (93 > 88 characters)
10    >>> import test_functions
11    >>> rosenbrock = test_functions.Rosenbrock()
12    >>> x = torch.linspace(rosenbrock.x_domain[0], rosenbrock.x_domain[1], rosenbrock.num_pt)
13    >>> y = torch.linspace(rosenbrock.y_domain[0], rosenbrock.y_domain[1], rosenbrock.num_pt)14    >>> Y, X = torch.meshgrid(x, y)
15    >>> Z = rosenbrock([X, Y])
16
line too long (93 > 88 characters)
 9    Example:
10    >>> import test_functions
11    >>> rosenbrock = test_functions.Rosenbrock()
12    >>> x = torch.linspace(rosenbrock.x_domain[0], rosenbrock.x_domain[1], rosenbrock.num_pt)13    >>> y = torch.linspace(rosenbrock.y_domain[0], rosenbrock.y_domain[1], rosenbrock.num_pt)
14    >>> Y, X = torch.meshgrid(x, y)
15    >>> Z = rosenbrock([X, Y])
line too long (90 > 88 characters)
10        num_pt: number of point in the search domain
11        levels: determines the number and positions of the contour lines / regions.
12    """
13    def __init__(self, x_domain: iter, y_domain: iter, minimum: iter, initial_state: iter,14                 num_pt: int = 250, levels: int = 50):
15        self._x_domain = x_domain
16        self._y_domain = y_domain