This release is a pre-release and may not be stable for production use.
====
##Description
ADPY is a Python library for algorithmic differentiation (http://en.wikipedia.org/wiki/Automatic_differentiation).
It aims to provide an easy way to extract partial derivatives of vector valued function (Jacobian matrix). In addition it allows to created callable function for obtaining function values using computational graphs.
Features:
* optimize numerical evaluation by using computational graph
* create callable function from Sympy expressions (calls lambdify once and creates a computational graph)
* extract partial derivatives using forward or reverse algorithmic differentiation
* bonus: a small nonlinear solver using all advantages mentioned above
##How to use
Due the small amount of features the handling is quite easy.
For the easiest use you need a callable function which takes a list of float numbers and returns a list.
def f(x):
return [x[0]**2,2*x[1]]
You need a valid values for x which cause no singularities while evaluating the function.
x1 = [1.,2.]
Initialize the ADFUN object.
from ADPY import adfun
adpy_test = adfun(f,x1)
Now you have a callable function with computational graph optimization.
y1 = adpy_test(x1)
If you want to use derivatives just do
adpy_test.init_reverse_jac()
or
adpy_test.init_forward_jac()
Now you can evaluate them using
J_forward = adpy_test.jac_reverse(x1)
or
J_forward = adpy_test.jac_forward(x1)
For more information see the attached examples.
##Install
clone git
git clone https://github.com/zwenson/ADPY
and run setup.py
python setup.py install
or use easy_install
easy_install ADPY
##How it works
Without going in to detail. It uses an overloaded class "adfloat" to record a list of the mathematical operations required to obtain the result. This list is then translated in to python expressions and made executable. The list is also used to perform automatic differentiation.
##To do
* more testing
* add more operations
* maybe add Hessian matrix?
* add Taylor arithmetic?
Metadata
Release files for ADPY 0.12.alpha
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| ADPY-0.12.alpha.tar.gz | 8.2 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| ADPY-0.12.alpha-py2.7.egg | Legacy Egg format | - | - | Details |
Total release size: 31.4 kB
Release files / ADPY-0.12.alpha.tar.gz
| Download URL | ADPY-0.12.alpha.tar.gz |
|---|---|
| Size | 8.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a27d0a2eaeb2fe7ed555c1e38327b3472374a963ca2b9c023089989ed54589c6
|
|
BLAKE2b-256 checksum How to use checksums |
9b5a90d0a5a2260de3f3174c069c3ae84bf2102518ebb4d4293d3d6951a83a26
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / ADPY-0.12.alpha-py2.7.egg
| Download URL | ADPY-0.12.alpha-py2.7.egg |
|---|---|
| Size | 23.2 kB |
| Tags | Egg |
|
SHA-256 checksum How to use checksums |
dcc120f17de4f8e31c66aa18f4c4175f17d6abfd0dce103b412561d6ac1ee110
|
|
BLAKE2b-256 checksum How to use checksums |
a5b6a7101ead8ce7748e77c6998eb6c29d423563e7cdb0564e2661dba60e19ee
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for ADPY 0.12.alpha
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.