algopy 0.7.2
Scientific differentiation library; no malicious behavior
Module is one triple-quoted Python literalPython bitwise XOR expression
SHA-2564a82ba3d44964430733c5c44c498779ac84879cabf70b31136d550b5e6252d51
Evidence
14:89… ation,forward mode,reverse mode,Taylor arithmetic
15Platform: all
16Requires-Python: >=3.6
17Description-Content-Type: text/x-rst
18Requires-Dist: numpy>=2.0.0
19Requires-Dist: scipy>=1.14.0
20Requires-Dist: pytest>=8.2.2
21
22AlgoPy, a library for Automatic Differentation (AD) in Python
23------ …
99:4… .. _PYTORCH: https://pytorch.org/
100
101Email:
102
104
105How to cite AlgoPy::
⋯4 lines
⋯4 lines
53"""
54
55import os
56__install_path__ = os.path.realpath(__file__)
57
58
59# check that dependencies are satisfied
60
61from ._npversion import NumpyVersion
62
63_min_numpy_version = '2.0.0'
64_preferred_numpy_version = '2.0.0'
65_min_scipy_version = '1.14.0'
66
67try:
68 import numpy
69
70 # ignore warnings "ComplexWarning: Casting complex values to real discards the imaginary part"
71 import warnings
72 warnings.simplefilter("ignore", numpy.exceptions.ComplexWarning)
73
74except ImportError as e:
75 raise ImportError(
76 "NumPy import error (%s)\n"
77 "NumPy is a requirement of AlgoPy.\n"
78 "Please install NumPy >= %s" % (e, _p …
84:20… py.version.version, _preferred_numpy_version))
85
86try:
87 import scipy
88except ImportError as e:
89 raise ImportError(
90 "SciPy import error (%s)\n"
91 "SciPy is a requirement of AlgoPy.\ …
101:28… s and important classes/functions
102from . import tracer
103from .tracer import CGraph, Function
104
105from . import utpm
106from .utpm import UTPM, UTP
107
108from . import globalfuncs
109from .globalfuncs import *
110
111from .compound import *
112
113from . import special
114
115from . import linalg
116from .linalg import *
117
118from . import nthderiv
119
120from . import fft
121
122try:
123 from . import version
124 __version__ = version.version
125
126except ImportError:
127 __version__ = 'nobuild'
128
129
130def test():
131 try:
132 import pytest
133 import pathlib
134 local_path = pathlib.Path(__file__).parent.resolve()
135
136 except:
137 print('Please install pytest.')
138
139
140 pytest.main(["-x", local_path]) …
Showing the top 5 files — 8 more files (55 regions) not shown.
No evidence locations were recorded for this file. Raw result