-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add makefile and CI to check analysis notebooks work
- Loading branch information
Showing
4 changed files
with
82 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: CI | ||
|
||
concurrency: | ||
group: ${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
on: | ||
push: { branches: [ "main" ] } | ||
pull_request: { branches: [ "main" ] } | ||
|
||
jobs: | ||
test: | ||
|
||
runs-on: ubuntu-latest | ||
container: condaforge/mambaforge:latest | ||
|
||
steps: | ||
- uses: actions/[email protected] | ||
|
||
- name: Setup Conda Environment | ||
run: | | ||
apt update && apt install -y git make | ||
make env | ||
- name: Test Analysis | ||
run: | | ||
make test-analysis |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
PACKAGE_NAME := a3fe_reproduce | ||
CONDA_ENV_RUN := conda run --no-capture-output --name $(PACKAGE_NAME) | ||
|
||
ANALYSIS_NBS := $(wildcard analysis/*.ipynb) | ||
|
||
.PHONY: env test-analysis | ||
|
||
env: | ||
mamba create --name $(PACKAGE_NAME) | ||
mamba env update --name $(PACKAGE_NAME) --file devtools/envs/base.yaml | ||
$(CONDA_ENV_RUN) pip install --no-build-isolation --no-deps git+https://github.com/michellab/a3fe.git | ||
|
||
test-analysis: | ||
$(CONDA_ENV_RUN) jupyter nbconvert --to notebook --execute $(ANALYSIS_NBS) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{ | ||
"cells": [ | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"!echo \"Hello make world!\"" | ||
] | ||
} | ||
], | ||
"metadata": { | ||
"language_info": { | ||
"name": "python" | ||
} | ||
}, | ||
"nbformat": 4, | ||
"nbformat_minor": 2 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
name: a3fe_reproduce | ||
|
||
channels: | ||
- conda-forge | ||
- "openbiosim/label/dev" | ||
|
||
dependencies: | ||
# Base depends | ||
- arviz | ||
- pandas | ||
- python | ||
- pip | ||
- numpy | ||
- matplotlib | ||
- scipy | ||
- ipython | ||
- pymbar<4 | ||
- ambertools | ||
- biosimspace>2023.4 | ||
- numpydoc | ||
- pydantic |