Skip to content

Commit

Permalink
Merge branch 'develop' into doc_all
Browse files Browse the repository at this point in the history
  • Loading branch information
dilpath authored Oct 15, 2024
2 parents 6c6ff4b + 72b076a commit 3497492
Show file tree
Hide file tree
Showing 10 changed files with 58 additions and 12 deletions.
11 changes: 11 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
version: 2
updates:

- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
ignore:
- dependency-name: "*"
update-types: ["version-update:semver-patch", "version-update:semver-minor"]
target-branch: "develop"
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
strategy:
matrix:
# test on latest and minimum python version
python-version: ['3.11', '3.9']
python-version: ['3.12', '3.10']

steps:
- name: Check out repository
Expand Down
34 changes: 34 additions & 0 deletions .github/workflows/deploy_release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Deploy
on:
release:
types:
- published

jobs:
pypi:
name: Deploy PyPI
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/p/petab-select
permissions:
id-token: write

steps:
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"

- uses: actions/checkout@v4
with:
fetch-depth: 20

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install setuptools wheel build
python -m build -s
- name: Publish a Python distribution to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# PEtab Select

[![PyPI - Version](https://img.shields.io/pypi/v/petab-select)](https://pypi.org/project/petab-select/)

The repository for the development of the extension to PEtab for model
selection, including the additional file formats and Python 3 package.

Expand Down
4 changes: 2 additions & 2 deletions doc/examples/workflow_cli.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"source": [
"In each call to `petab_select search`, the following options are required:\n",
"- `-y`: The PEtab Select problem YAML file;\n",
"- `-s`: A file that is used to stored the state of the problem (e.g., such that models are not repeated);\n",
"- `-s`: A file that is used to store the state of the problem (e.g., such that models are not repeated);\n",
"- `-o`: A file to store the output of the model space search; and\n",
"- `-m`: The method used to search or identify models in the model space.\n",
"\n",
Expand Down Expand Up @@ -570,7 +570,7 @@
"id": "655f8efc",
"metadata": {},
"source": [
"# Post-processing\n",
"## Post-processing\n",
"After the selection algorithm has terminated, the best model can be stored separately by supplying a list of calibrated models."
]
},
Expand Down
4 changes: 2 additions & 2 deletions petab_select/criteria.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
"""Implementations of model selection criteria."""

import numpy as np
import petab
from petab.C import OBJECTIVE_PRIOR_PARAMETERS, OBJECTIVE_PRIOR_TYPE
import petab.v1 as petab
from petab.v1.C import OBJECTIVE_PRIOR_PARAMETERS, OBJECTIVE_PRIOR_TYPE

import petab_select

Expand Down
4 changes: 2 additions & 2 deletions petab_select/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
from pathlib import Path
from typing import Any, Dict, List, Optional, Tuple, Union

import petab
import petab.v1 as petab
import yaml
from more_itertools import one
from petab.C import ESTIMATE, NOMINAL_VALUE
from petab.v1.C import ESTIMATE, NOMINAL_VALUE

from .constants import (
CRITERIA,
Expand Down
4 changes: 2 additions & 2 deletions petab_select/petab.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from pathlib import Path
from typing import List, Optional

import petab
import petab.v1 as petab
from more_itertools import one
from petab.C import ESTIMATE, NOMINAL_VALUE
from petab.v1.C import ESTIMATE, NOMINAL_VALUE

from .constants import PETAB_ESTIMATE_FALSE, TYPE_PARAMETER_DICT, TYPE_PATH

Expand Down
2 changes: 1 addition & 1 deletion petab_select/ui.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from typing import Dict, List, Optional, Union

import numpy as np
import petab
import petab.v1 as petab

from .candidate_space import CandidateSpace, FamosCandidateSpace
from .constants import (
Expand Down
3 changes: 1 addition & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@ def absolute_links(txt):
return txt


# 3.7.1 for NumPy, 3.8 for `typing.get_args`
minimum_python_version = '3.8'
minimum_python_version = '3.10'
if sys.version_info < tuple(map(int, minimum_python_version.split('.'))):
sys.exit(f'PEtab Select requires Python >= {minimum_python_version}')

Expand Down

0 comments on commit 3497492

Please sign in to comment.