1b93cfeca5f2503eafc4ec773353254cf077fb9f,torchdiffeq/_impl/fixed_adams.py,AdamsBashforthMoulton,_has_converged,#AdamsBashforthMoulton#Any#Any#,171

Before Change


        Checks that each element is within the error tolerance.
        error_tol = _error_tol(self.rtol, self.atol, y0, y1)
        error = tuple(torch.abs(y0_ - y1_) for y0_, y1_ in zip(y0, y1))
        return all((error_ < error_tol_).all() for error_, error_tol_ in zip(error, error_tol))

    def _step_func(self, func, t, dt, y):
        self._update_history(t, func(t, y))

After Change


        Checks that each element is within the error tolerance.
        error_tol = _error_tol(self.rtol, self.atol, y0, y1)
        error = torch.abs(y0 - y1)
        return (error < error_tol).all()

    def _step_func(self, func, t, dt, y):
        self._update_history(t, func(t, y))
        order = min(len(self.prev_f), self.max_order - 1)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: rtqichen/torchdiffeq
Commit Name: 1b93cfeca5f2503eafc4ec773353254cf077fb9f
Time: 2020-07-28
Author: 33688385+patrick-kidger@users.noreply.github.com
File Name: torchdiffeq/_impl/fixed_adams.py
Class Name: AdamsBashforthMoulton
Method Name: _has_converged


Project Name: matplotlib/matplotlib
Commit Name: 34b8eb46e5de6b760bc131e461755042716e259d
Time: 2018-02-07
Author: story645@gmail.com
File Name: lib/matplotlib/category.py
Class Name: StrCategoryConverter
Method Name: convert


Project Name: scikit-optimize/scikit-optimize
Commit Name: 544875dd8a7fea49a86e5623d37274159b4ba7b5
Time: 2017-01-10
Author: betatim@gmail.com
File Name: skopt/optimizer/base.py
Class Name:
Method Name: base_minimize