A basic library for constructing dynamics experiments
Project description
Overview
A library for constructing dynamics experiments from the dynamics models in the dysts package.
This includes data generation and model evaluation.
The first contribution is the static typing of trajectory data (ProbData) that, I believe, provides the necessary information to be useful in evaluating a wide variety of dynamics/time-series learning methods.
The second contribution is the collection of utility functions for designing dynamics learning experiments.
The third contribution is the collection of such experiments for evaluating dynamics/time-series learning models that meet the BaseSINDy API.
It aims to (a) be amenable to both numpy and jax arrays, (b) be usable by any dynamics/time-series learning models that meet the BaseSINDy or scikit-time API.
Internally, this package is used/will be used in benchmarking pysindy runtime/memory usage and choosing default hyperparameters.
Getting started
Install with pip install sindy-exp or pip install sindy-exp[jax].
Generate data
data = sindy_exp.data.gen_data("lorenz", num_trajectories=5, t_end=10.0, dt=0.01)["data]
Evaluate your SINDy-like model with:
sindy_exp.odes.fit_eval(model, data)
A list of available ODE systems can be found in ODE_CLASSES, which includes most
of the systems from the dysts package as well as some non-chaotic systems.
ODE & Data Model
Generated or measured data has the dataclass type ProbData or SimProbData, respectively,
to indicate whether it includes ground truth information and a noise level.
If the data is generated in jax, it will have an integrator that can later be used to evaluate the true data on collocation points.
We deal primarily with autonomous ODE systems of the form:
dx/dt = sum_i f_i(x)
We represent ODE systems as a list of right-hand side expressions.
Each element is a dictionary mapping a term (Sympy expression) to its coefficient.
Thus, the rhs of an ODE is of type: list[dict[sympy.Expr, float]]
Other useful imports, compatibility, and extensions
- The experiments are built to be compatible with the
mitosistool, an experiment runner. Mitosis is not a dependency, however, to allow using other experiment runners. - To integrate your own experiments or data generation in a way that is compatible, see the
ProbData,SimProbData,DynamicsTrialData, andFullDynamicsTrialDataclasses. - For plotting tools, see
plot_coefficients,compare_coefficient_plots_from_dicts,plot_test_trajectory,plot_training_data, andCOLOR. - For evaluation of models, see
coeff_metrics,pred_metrics, andintegration_metrics.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sindy_exp-0.3.0.tar.gz.
File metadata
- Download URL: sindy_exp-0.3.0.tar.gz
- Upload date:
- Size: 332.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
05bef5f0a51909e43d4ddeb31e0a61e59317fdf4ffbf6d209d417242004df549
|
|
| MD5 |
0f93d210c7ac2d20410bda141329d8c7
|
|
| BLAKE2b-256 |
5d570d585efb58469ed18938f06bd970c38374fd4154241a688108fc57d4f6e7
|
Provenance
The following attestation bundles were made for sindy_exp-0.3.0.tar.gz:
Publisher:
release.yml on Jacob-Stevens-Haas/pysindy-experiments
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
sindy_exp-0.3.0.tar.gz -
Subject digest:
05bef5f0a51909e43d4ddeb31e0a61e59317fdf4ffbf6d209d417242004df549 - Sigstore transparency entry: 909264750
- Sigstore integration time:
-
Permalink:
Jacob-Stevens-Haas/pysindy-experiments@002fcbc61a5f58aa4570d4eb1aa8414108ebac61 -
Branch / Tag:
refs/tags/v0.3.0 - Owner: https://github.com/Jacob-Stevens-Haas
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@002fcbc61a5f58aa4570d4eb1aa8414108ebac61 -
Trigger Event:
push
-
Statement type:
File details
Details for the file sindy_exp-0.3.0-py3-none-any.whl.
File metadata
- Download URL: sindy_exp-0.3.0-py3-none-any.whl
- Upload date:
- Size: 26.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3d3359aad4d9e93b00f4a619e2092fd95ee373e208e61fd5b937fe2bd16ee41c
|
|
| MD5 |
00c62ef401589b97ab0deb30113f762c
|
|
| BLAKE2b-256 |
73d39b7d892f5e9076b382c3e531daa276f9fff81727a8f73aca8a0f9d97901a
|
Provenance
The following attestation bundles were made for sindy_exp-0.3.0-py3-none-any.whl:
Publisher:
release.yml on Jacob-Stevens-Haas/pysindy-experiments
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
sindy_exp-0.3.0-py3-none-any.whl -
Subject digest:
3d3359aad4d9e93b00f4a619e2092fd95ee373e208e61fd5b937fe2bd16ee41c - Sigstore transparency entry: 909264752
- Sigstore integration time:
-
Permalink:
Jacob-Stevens-Haas/pysindy-experiments@002fcbc61a5f58aa4570d4eb1aa8414108ebac61 -
Branch / Tag:
refs/tags/v0.3.0 - Owner: https://github.com/Jacob-Stevens-Haas
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@002fcbc61a5f58aa4570d4eb1aa8414108ebac61 -
Trigger Event:
push
-
Statement type: