We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fad = g.ad.forward alpha = fad.infinitesimal("alpha") On = fad.landau(alpha**2) series = fad.series(3, On) arr = np.arange(1, 10, 1) print(((series + arr) - (arr + series)))
This should print a series of zeroes. Instead, a series of series is printed.
One can fix this by monkey-patching the series class:
series
fad = g.ad.forward alpha = fad.infinitesimal("alpha") On = fad.landau(alpha**2) fad.series.__array_ufunc__ = None # For numpy < 13, add also __numpy_ufunc__. series = fad.series(3, On) arr = np.arange(1, 10, 1) print(((series + arr) - (arr + series)))
The patch to fix this appears straight forward.
The text was updated successfully, but these errors were encountered:
added test for ad.forward.series objects with numpy arrays, fixes leh…
c4d20c5
…ner#139
Successfully merging a pull request may close this issue.
This should print a series of zeroes. Instead, a series of series is printed.
One can fix this by monkey-patching the
series
class:The patch to fix this appears straight forward.
The text was updated successfully, but these errors were encountered: