Skip to content

Commit

Permalink
Merge branch 'develop' into test_numpy2
Browse files Browse the repository at this point in the history
  • Loading branch information
dweindl authored Apr 29, 2024
2 parents 360d8ad + a1d1451 commit df63406
Show file tree
Hide file tree
Showing 100 changed files with 873 additions and 438 deletions.
1 change: 1 addition & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
f59fed72eb4d0cedf6abf2a96fe95087ce61478a
2 changes: 1 addition & 1 deletion .github/workflows/deploy_branch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:

strategy:
matrix:
python-version: [3.9]
python-version: ["3.11"]

steps:
- name: Set up Python ${{ matrix.python-version }}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/deploy_protected.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,14 @@ jobs:
fi
dockerhub:
name: Deploy Dockerhub
name: Deploy Docker Hub
needs: [check-secret]
if: needs.check-secret.outputs.secrets-defined == 'true'
runs-on: ubuntu-22.04

strategy:
matrix:
python-version: [3.9]
python-version: ["3.11"]

steps:
- name: Set up Python ${{ matrix.python-version }}
Expand All @@ -50,7 +50,7 @@ jobs:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Publish to Registry
uses: elgohr/Publish-Docker-Github-Action@v4
uses: elgohr/Publish-Docker-Github-Action@v5
with:
name: dweindl/amici
username: ${{ secrets.DOCKER_USERNAME }}
Expand Down
30 changes: 28 additions & 2 deletions .github/workflows/deploy_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:

strategy:
matrix:
python-version: [3.9]
python-version: ["3.11"]

environment:
name: pypi
Expand All @@ -39,7 +39,7 @@ jobs:
- name: Remove direct dependencies from setup.cfg
# Remove any "git+https"-based dependencies that are not supported
# by PyPI and are only required for testing.
run: sed -i '/git+https/d' python/sdist/setup.cfg
run: sed -i '/git+https/d' python/sdist/pyproject.toml

- name: sdist
run: scripts/buildSdist.sh
Expand Down Expand Up @@ -74,3 +74,29 @@ jobs:
-H "Accept: application/vnd.github.v3+json" \
https://api.github.com/repos/${DOWNSTREAM_REPOSITORY}/actions/workflows/${WORKFLOW_FILE}/dispatches \
-d "{\"ref\": \"dev\", \"inputs\": {\"simulatorVersion\": \"${PACKAGE_VERSION}\", \"simulatorVersionLatest\": \"true\"}}"
dockerhub:
name: Release to Docker Hub
runs-on: ubuntu-22.04

steps:
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"
- uses: actions/checkout@v4
- run: git archive -o container/amici.tar.gz --format=tar.gz HEAD
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Publish to Registry
uses: elgohr/Publish-Docker-Github-Action@v5
with:
name: dweindl/amici
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
workdir: container/
dockerfile: Dockerfile
tag_semver: true
platforms: linux/amd64,linux/arm64
2 changes: 1 addition & 1 deletion .github/workflows/test_benchmark_collection_models.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: [ "3.9" ]
python-version: [ "3.11" ]
extract_subexpressions: ["true", "false"]
env:
AMICI_EXTRACT_CSE: ${{ matrix.extract_subexpressions }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_doc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:

strategy:
matrix:
python-version: [3.9]
python-version: ["3.11"]

steps:
- name: Set up Python ${{ matrix.python-version }}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/test_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:

strategy:
matrix:
python-version: [3.9]
python-version: ["3.11"]

steps:
- name: Set up Python ${{ matrix.python-version }}
Expand Down Expand Up @@ -50,7 +50,7 @@ jobs:

strategy:
matrix:
python-version: [3.9]
python-version: ["3.11"]

steps:
- name: Set up Python ${{ matrix.python-version }}
Expand Down Expand Up @@ -83,7 +83,7 @@ jobs:

strategy:
matrix:
python-version: [3.9]
python-version: ["3.11"]

steps:
- name: Set up Python ${{ matrix.python-version }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_performance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:

strategy:
matrix:
python-version: [3.9]
python-version: ["3.11"]

steps:
- name: Set up Python ${{ matrix.python-version }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_petab_test_suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:

strategy:
matrix:
python-version: [3.9]
python-version: ["3.11"]

steps:
- name: Set up Python ${{ matrix.python-version }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12"]
python-version: ["3.10", "3.11", "3.12"]
os: [ubuntu-22.04, macos-latest]

runs-on: ${{ matrix.os }}
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/test_python_cplusplus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

strategy:
matrix:
python-version: [ "3.9" ]
python-version: [ "3.11" ]

steps:
- name: Cache
Expand Down Expand Up @@ -117,7 +117,7 @@ jobs:

strategy:
matrix:
python-version: [ "3.9" ]
python-version: [ "3.10" ]

steps:
- name: Set up Python ${{ matrix.python-version }}
Expand Down Expand Up @@ -193,7 +193,7 @@ jobs:

strategy:
matrix:
python-version: [ "3.9" ]
python-version: [ "3.11" ]

steps:
- name: Set up Python ${{ matrix.python-version }}
Expand Down Expand Up @@ -233,7 +233,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.9
python-version: "3.11"

- uses: actions/checkout@v4
- run: git fetch --prune --unshallow
Expand Down Expand Up @@ -282,7 +282,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.9
python-version: "3.11"

- uses: actions/checkout@v4
- run: git fetch --prune --unshallow
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_python_ver_matrix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ['3.9', '3.10', '3.11', '3.12']
python-version: ['3.10', '3.11', '3.12']
experimental: [false]

steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_sbml_semantic_test_suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
matrix:
cases: ["1-250", "251-500", "501-750", "751-1000",
"1000-1250", "1251-"]
python-version: [ "3.9" ]
python-version: [ "3.11" ]

steps:
- name: Set up Python ${{ matrix.python-version }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test_valgrind.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:

strategy:
matrix:
python-version: [ "3.9" ]
python-version: [ "3.11" ]

env:
ENABLE_AMICI_DEBUGGING: "TRUE"
Expand Down Expand Up @@ -57,7 +57,7 @@ jobs:

strategy:
matrix:
python-version: [ "3.9" ]
python-version: [ "3.11" ]

env:
ENABLE_AMICI_DEBUGGING: "TRUE"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:

strategy:
matrix:
python-version: [ "3.9" ]
python-version: [ "3.11" ]

steps:
- name: Set up Python ${{ matrix.python-version }}
Expand Down
9 changes: 4 additions & 5 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
rev: v4.6.0
hooks:
- id: check-added-large-files
- id: check-merge-conflict
Expand All @@ -12,7 +12,7 @@ repos:
- id: trailing-whitespace
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.1.11
rev: v0.4.1
hooks:
# Run the linter.
- id: ruff
Expand All @@ -28,10 +28,9 @@ repos:
- python/sdist/pyproject.toml

- repo: https://github.com/asottile/pyupgrade
rev: v3.15.0
rev: v3.15.2
hooks:
- id: pyupgrade
args: ["--py39-plus"]
additional_dependencies: [pyupgrade==3.15.0]
args: ["--py310-plus"]

exclude: '^(ThirdParty|models)/'
42 changes: 42 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,48 @@

## v0.X Series

### v0.24.0 (2024-04-22)

This will be the last release supporting Python 3.9.
Future releases will require Python 3.10.

**Fixes**

* Fix cmake error `cannot create directory: /cmake/Amici`
during model import in cases where BLAS was not found via `FindBLAS`
by @dweindl in https://github.com/AMICI-dev/AMICI/pull/2389
* Added status code `AMICI_CONSTR_FAIL`
by @dweindl in https://github.com/AMICI-dev/AMICI/pull/2379
* Fixed certain initial state issues with PEtab
by @dweindl in https://github.com/AMICI-dev/AMICI/pull/2382
* Fixed Solver `operator==` and copyctor
(constraints were not copied correctly)
by @dweindl in https://github.com/AMICI-dev/AMICI/pull/2388
* Avoid confusing warnings about non-finite timepoints
by @dweindl in https://github.com/AMICI-dev/AMICI/pull/2395
* Fixed incorrect exception types / messages for `IDASolver`
by @dweindl in https://github.com/AMICI-dev/AMICI/pull/2398
* cmake: set SUNDIALS path hint for python package to help CMake find
the correct SUNDIALS installation
by @dweindl in https://github.com/AMICI-dev/AMICI/pull/2397

* **Features**

* Optionally include measurements in `plot_observable_trajectories`
by @dweindl in https://github.com/AMICI-dev/AMICI/pull/2381
* Improved type annotations in swig-wrappers
by @dweindl in https://github.com/AMICI-dev/AMICI/pull/2401
* Additional attributes are accessible directly via `ReturnDataView` and
`ExpDataView`, e.g. `ReturnDataView.ny`, `ReturnDataView.nx`
by @dweindl in https://github.com/AMICI-dev/AMICI/pull/2405
* Allow subselection of state variables for convergence check during
steady-state simulations via `Model.set_steadystate_mask([1, 0, ..., 1])`
(positive value: check; non-positive: don't check).
by @dweindl in https://github.com/AMICI-dev/AMICI/pull/2387

**Full Changelog**: https://github.com/AMICI-dev/AMICI/compare/v0.23.1...v0.24.0


### v0.23.1 (2024-03-11)

* Fixes installation issues related to building SuiteSparse on some systems
Expand Down
31 changes: 31 additions & 0 deletions documentation/amici_refs.bib
Original file line number Diff line number Diff line change
Expand Up @@ -1275,6 +1275,37 @@ @Article{SluijsZho2024
publisher = {Springer Science and Business Media LLC},
}
@Article{KissVen2024,
author = {Kiss, Anna E and Venkatasubramani, Anuroop V and Pathirana, Dilan and Krause, Silke and Sparr, Aline Campos and Hasenauer, Jan and Imhof, Axel and Müller, Marisa and Becker, Peter B},
journal = {Nucleic Acids Research},
title = {{Processivity and specificity of histone acetylation by the male-specific lethal complex}},
year = {2024},
issn = {0305-1048},
month = {02},
pages = {gkae123},
abstract = {{Acetylation of lysine 16 of histone H4 (H4K16ac) stands out among the histone modifications, because it decompacts the chromatin fiber. The metazoan acetyltransferase MOF (KAT8) regulates transcription through H4K16 acetylation. Antibody-based studies had yielded inconclusive results about the selectivity of MOF to acetylate the H4 N-terminus. We used targeted mass spectrometry to examine the activity of MOF in the male-specific lethal core (4-MSL) complex on nucleosome array substrates. This complex is part of the Dosage Compensation Complex (DCC) that activates X-chromosomal genes in male Drosophila. During short reaction times, MOF acetylated H4K16 efficiently and with excellent selectivity. Upon longer incubation, the enzyme progressively acetylated lysines 12, 8 and 5, leading to a mixture of oligo-acetylated H4. Mathematical modeling suggests that MOF recognizes and acetylates H4K16 with high selectivity, but remains substrate-bound and continues to acetylate more N-terminal H4 lysines in a processive manner. The 4-MSL complex lacks non-coding roX RNA, a critical component of the DCC. Remarkably, addition of RNA to the reaction non-specifically suppressed H4 oligo-acetylation in favor of specific H4K16 acetylation. Because RNA destabilizes the MSL-nucleosome interaction in vitro we speculate that RNA accelerates enzyme-substrate turn-over in vivo, thus limiting the processivity of MOF, thereby increasing specific H4K16 acetylation.}},
creationdate = {2024-02-28T18:25:06},
doi = {10.1093/nar/gkae123},
eprint = {https://academic.oup.com/nar/advance-article-pdf/doi/10.1093/nar/gkae123/56756494/gkae123.pdf},
modificationdate = {2024-02-28T18:25:06},
url = {https://doi.org/10.1093/nar/gkae123},
}
@Article{DoresicGre2024,
author = {Domagoj Dore{\v s}i{\'c} and Stephan Grein and Jan Hasenauer},
journal = {bioRxiv},
title = {Efficient parameter estimation for ODE models of cellular processes using semi-quantitative data},
year = {2024},
abstract = {Quantitative dynamical models facilitate the understanding of biological processes and the prediction of their dynamics. The parameters of these models are commonly estimated from experimental data. Yet, experimental data generated from different techniques do not provide direct information about the state of the system but a non-linear (monotonic) transformation of it. For such semi-quantitative data, when this transformation is unknown, it is not apparent how the model simulations and the experimental data can be compared. Here, we propose a versatile spline-based approach for the integration of a broad spectrum of semi-quantitative data into parameter estimation. We derive analytical formulas for the gradients of the hierarchical objective function and show that this substantially increases the estimation efficiency. Subsequently, we demonstrate that the method allows for the reliable discovery of unknown measurement transformations. Furthermore, we show that this approach can significantly improve the parameter inference based on semi-quantitative data in comparison to available methods. Modelers can easily apply our method by using our implementation in the open-source Python Parameter EStimation TOolbox (pyPESTO).Competing Interest StatementThe authors have declared no competing interest.},
creationdate = {2024-04-20T13:05:06},
doi = {10.1101/2024.01.26.577371},
elocation-id = {2024.01.26.577371},
eprint = {https://www.biorxiv.org/content/early/2024/01/30/2024.01.26.577371.full.pdf},
modificationdate = {2024-04-20T13:05:06},
publisher = {Cold Spring Harbor Laboratory},
url = {https://www.biorxiv.org/content/early/2024/01/30/2024.01.26.577371},
}
@Comment{jabref-meta: databaseType:bibtex;}
@Comment{jabref-meta: grouping:
Expand Down
8 changes: 4 additions & 4 deletions documentation/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -558,15 +558,15 @@ def fix_typehints(sig: str) -> str:
sig = sig.replace("sunindextype", "int")
sig = sig.replace("H5::H5File", "object")

# remove const
sig = sig.replace(" const ", r" ")
sig = re.sub(r" const$", r"", sig)
# remove const / const&
sig = sig.replace(" const&? ", r" ")
sig = re.sub(r" const&?$", r"", sig)

# remove pass by reference
sig = re.sub(r" &(,|\))", r"\1", sig)
sig = re.sub(r" &$", r"", sig)

# turn gsl_spans and pointers int Iterables
# turn gsl_spans and pointers into Iterables
sig = re.sub(r"([\w.]+) \*", r"Iterable[\1]", sig)
sig = re.sub(r"gsl::span< ([\w.]+) >", r"Iterable[\1]", sig)

Expand Down
Binary file modified documentation/gfx/amici_workflow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit df63406

Please sign in to comment.