Skip to content

Commit

Permalink
Update AMICI to v0.20.0
Browse files Browse the repository at this point in the history
git subrepo clone (merge) --branch=v0.20.0 --force git@github.com:AMICI-dev/AMICI.git deps/AMICI

subrepo:
  subdir:   "deps/AMICI"
  merged:   "ffcbf665"
upstream:
  origin:   "git@github.com:AMICI-dev/AMICI.git"
  branch:   "v0.20.0"
  commit:   "ffcbf665"
git-subrepo:
  version:  "0.4.6"
  origin:   "https://github.com/ingydotnet/git-subrepo"
  commit:   "110b9eb"
  • Loading branch information
dweindl committed Dec 5, 2023
1 parent 540e2f4 commit 9d36c99
Show file tree
Hide file tree
Showing 985 changed files with 65,591 additions and 61,258 deletions.
105 changes: 11 additions & 94 deletions deps/AMICI/.clang-format
Original file line number Diff line number Diff line change
@@ -1,96 +1,13 @@
---
BasedOnStyle: LLVM
IndentWidth: 4
---
Language: Cpp
# BasedOnStyle: LLVM
AccessModifierOffset: -2
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignEscapedNewlinesLeft: false
AlignOperands: true
AlignTrailingComments: true
AllowAllParametersOfDeclarationOnNextLine: true
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: All
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterDefinitionReturnType: None
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: false
BinPackArguments: true
BinPackParameters: true
BraceWrapping:
AfterClass: false
AfterControlStatement: false
AfterEnum: false
AfterFunction: false
AfterNamespace: false
AfterObjCDeclaration: false
AfterStruct: false
AfterUnion: false
BeforeCatch: false
BeforeElse: false
IndentBraces: false
BreakBeforeBinaryOperators: None
BreakBeforeBraces: Attach
BreakBeforeTernaryOperators: true
BreakConstructorInitializersBeforeComma: false
BreakAfterJavaFieldAnnotations: false
BreakStringLiterals: true
ColumnLimit: 80
CommentPragmas: '^ IWYU pragma:'
ConstructorInitializerAllOnOneLineOrOnePerLine: false
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 4
Cpp11BracedListStyle: true
DerivePointerAlignment: false
DisableFormat: false
ExperimentalAutoDetectBinPacking: false
ForEachMacros: [ foreach, Q_FOREACH, BOOST_FOREACH ]
IncludeCategories:
- Regex: '^"(llvm|llvm-c|clang|clang-c)/'
Priority: 2
- Regex: '^(<|"(gtest|isl|json)/)'
Priority: 3
- Regex: '.*'
Priority: 1
IncludeIsMainRegex: '$'
IndentCaseLabels: false
IndentWidth: 4
IndentWrappedFunctionNames: false
JavaScriptQuotes: Leave
JavaScriptWrapImports: true
KeepEmptyLinesAtTheStartOfBlocks: true
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 1
NamespaceIndentation: None
ObjCBlockIndentWidth: 2
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: true
PenaltyBreakBeforeFirstCallParameter: 19
PenaltyBreakComment: 300
PenaltyBreakFirstLessLess: 120
PenaltyBreakString: 1000
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 60
PointerAlignment: Right
ReflowComments: true
SortIncludes: true
SpaceAfterCStyleCast: false
SpaceAfterTemplateKeyword: true
SpaceBeforeAssignmentOperators: true
SpaceBeforeParens: ControlStatements
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1
SpacesInAngles: false
SpacesInContainerLiterals: true
SpacesInCStyleCastParentheses: false
SpacesInParentheses: false
SpacesInSquareBrackets: false
Standard: Cpp11
TabWidth: 8
UseTab: Never
...

AlignAfterOpenBracket: BlockIndent
BreakBeforeBinaryOperators: All
BreakConstructorInitializers: BeforeComma
ColumnLimit: 80
PointerAlignment: Left
QualifierAlignment: Custom
QualifierOrder: ['inline', 'static', 'type', 'const']
ReferenceAlignment: Left
1 change: 0 additions & 1 deletion deps/AMICI/.coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,3 @@ exclude_lines =
raise
except:
import

4 changes: 4 additions & 0 deletions deps/AMICI/.github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# see https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners

# default owners
* @AMICI-dev/amici-maintainers
16 changes: 16 additions & 0 deletions deps/AMICI/.github/actions/install-apt-dependencies/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Install apt dependencies
description: Install apt dependencies for the AMICI Python package
runs:
using: "composite"
steps:
- run: |
sudo apt-get update \
&& sudo apt-get install -y \
g++ \
libatlas-base-dev \
libboost-chrono-dev \
libboost-math-dev \
libboost-serialization-dev \
libhdf5-serial-dev \
swig
shell: bash
44 changes: 44 additions & 0 deletions deps/AMICI/.github/actions/setup-amici-cpp/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Set up AMICI C++
description: |
Build the AMICI C++ interface and set things for for coverage analysis.
(Currently ubuntu-only).
runs:
using: "composite"
steps:
# BioNetGen Path
- run: echo "BNGPATH=${GITHUB_WORKSPACE}/ThirdParty/BioNetGen-2.7.0" >> $GITHUB_ENV
shell: bash

# use all available cores
- run: echo "AMICI_PARALLEL_COMPILE=" >> $GITHUB_ENV
shell: bash

# enable coverage
- run: echo "ENABLE_GCOV_COVERAGE=TRUE" >> $GITHUB_ENV
shell: bash

- name: Set up Sonar tools
uses: ./.github/actions/setup-sonar-tools

- name: Install apt dependencies
uses: ./.github/actions/install-apt-dependencies

- name: Install additional apt dependencies
run: |
sudo apt-get update \
&& sudo apt-get install -y \
cmake \
python3-venv \
lcov
shell: bash

- name: Build AMICI dependencies
run: scripts/buildDependencies.sh
shell: bash

- name: Build AMICI
run: scripts/buildAmici.sh
shell: bash
env:
CI_SONARCLOUD: "TRUE"
20 changes: 20 additions & 0 deletions deps/AMICI/.github/actions/setup-doxygen/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Set up doxygen
description: |
Download, build, and install doxygen.
runs:
using: "composite"
steps:
- name: Install apt dependencies for doxygen
run: |
sudo apt-get update \
&& sudo apt-get install -y \
bison \
ragel \
graphviz \
texlive-latex-extra
shell: bash

- name: Download and build doxygen
run: sudo scripts/downloadAndBuildDoxygen.sh
shell: bash
26 changes: 26 additions & 0 deletions deps/AMICI/.github/actions/setup-sonar-tools/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Set up Sonar tools
description: Download and install sonar-scanner and build-wrapper
runs:
using: "composite"
steps:
- run: echo "SONAR_SCANNER_VERSION=5.0.1.3006" >> $GITHUB_ENV
shell: bash
- run: echo "SONAR_SCANNER_HOME=${HOME}/.sonar/sonar-scanner-$SONAR_SCANNER_VERSION-linux" >> $GITHUB_ENV
shell: bash
- run: echo "SONAR_SCANNER_OPTS=-server" >> $GITHUB_ENV
shell: bash
- run: echo "${SONAR_SCANNER_HOME}/bin" >> $GITHUB_PATH
shell: bash
- run: echo "${HOME}/.sonar/build-wrapper-linux-x86" >> $GITHUB_PATH
shell: bash

- name: Install sonarcloud tools
run: |
sudo apt-get install nodejs curl unzip \
&& curl --create-dirs -sSLo $HOME/.sonar/sonar-scanner.zip \
https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-$SONAR_SCANNER_VERSION-linux.zip \
&& unzip -o $HOME/.sonar/sonar-scanner.zip -d $HOME/.sonar/ \
&& curl --create-dirs -sSLo $HOME/.sonar/build-wrapper-linux-x86.zip \
https://sonarcloud.io/static/cpp/build-wrapper-linux-x86.zip \
&& unzip -o $HOME/.sonar/build-wrapper-linux-x86.zip -d $HOME/.sonar/ \
shell: bash
20 changes: 20 additions & 0 deletions deps/AMICI/.github/actions/setup-swig/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Set up SWIG
description: |
Download and build SWIG and set the SWIG environment variable to the path of
the SWIG executable.
inputs:
swig_version:
description: 'Swig version to build'
required: false
default: '4.1.1'

runs:
using: "composite"
steps:
- name: Download and build SWIG
run: scripts/downloadAndBuildSwig.sh
shell: bash

- run: echo "SWIG=${AMICI_DIR}/ThirdParty/swig-${{ inputs.swig_version }}/install/bin/swig" >> $GITHUB_ENV
shell: bash
16 changes: 7 additions & 9 deletions deps/AMICI/.github/workflows/deploy_branch.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: Deploy Branch
on: [push, pull_request, workflow_dispatch]
on: [push, merge_group, workflow_dispatch]

jobs:
sdist:
Expand All @@ -9,24 +9,22 @@ jobs:

strategy:
matrix:
python-version: [3.8]
python-version: [3.9]

steps:
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- uses: actions/checkout@master
- uses: actions/checkout@v3
with:
fetch-depth: 20

- run: echo "AMICI_DIR=$(pwd)" >> $GITHUB_ENV
- run: echo "SWIG=${AMICI_DIR}/ThirdParty/swig-4.0.1/install/bin/swig" >> $GITHUB_ENV
- name: Set up SWIG
uses: ./.github/actions/setup-swig

- name: Build swig4
run: |
sudo scripts/downloadAndBuildSwig.sh
- run: echo "AMICI_DIR=$(pwd)" >> $GITHUB_ENV

- name: Create AMICI sdist
run: |
Expand Down
22 changes: 15 additions & 7 deletions deps/AMICI/.github/workflows/deploy_protected.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,12 @@ on:
branches:
- master
- develop
- release**
pull_request:
branches:
- master
paths:
- container/Dockerfile
# ensure all relevant files are still included in sdist
- python/sdist/MANIFEST.in
workflow_dispatch:

jobs:
Expand All @@ -18,21 +21,26 @@ jobs:

strategy:
matrix:
python-version: [3.8]
python-version: [3.9]

steps:
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- uses: actions/checkout@master
- run: git archive -o docker/amici.tar.gz --format=tar.gz HEAD
- uses: actions/checkout@v3
- run: git archive -o container/amici.tar.gz --format=tar.gz HEAD
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Publish to Registry
uses: elgohr/Publish-Docker-Github-Action@v4
with:
name: dweindl/amici
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
workdir: docker/
workdir: container/
dockerfile: Dockerfile
tag_names: true
platforms: linux/amd64,linux/arm64
21 changes: 9 additions & 12 deletions deps/AMICI/.github/workflows/deploy_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,35 +12,32 @@ jobs:

strategy:
matrix:
python-version: [3.8]
python-version: [3.9]

steps:
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- uses: actions/checkout@master
- uses: actions/checkout@v3
with:
fetch-depth: 20

- run: echo "AMICI_DIR=$(pwd)" >> $GITHUB_ENV
- run: echo "SWIG=${AMICI_DIR}/ThirdParty/swig-4.0.1/install/bin/swig" >> $GITHUB_ENV
- name: Set up SWIG
uses: ./.github/actions/setup-swig

- name: Build swig4
run: |
sudo scripts/downloadAndBuildSwig.sh
- run: echo "AMICI_DIR=$(pwd)" >> $GITHUB_ENV

- name: sdist
run: |
scripts/buildSdist.sh
run: scripts/buildSdist.sh

- name: Publish a Python distribution to PyPI
uses: pypa/gh-action-pypi-publish@master
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.pypi_password }}
packages_dir: python/sdist/dist
packages-dir: python/sdist/dist

bioSimulatorsUpdateCliAndDockerImage:
name: Release to BioSimulators
Expand Down
Loading

0 comments on commit 9d36c99

Please sign in to comment.