Skip to content

Adding model to segment bones #162

Adding model to segment bones

Adding model to segment bones #162

Workflow file for this run

name: CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
Linting:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10"]
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- uses: actions/cache@v2
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip
- name: Install Dependencies
run: |
python -m pip install --upgrade pip
make dev
pip install --upgrade click==8.0.2
- name: Lint with isort, black, docformatter, flake8
run: |
make lint
Documentation:
needs: Linting
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.8", "3.9", "3.10"]
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- uses: actions/cache@v2
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip
- name: Install Dependencies
run: |
python -m pip install --upgrade pip
make dev
pip install -e '.[dev]'
- name: Generate Docs
run: |
make build-docs
Build:
needs: Documentation
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
python-version: ["3.7", "3.8", "3.9", "3.10"] # there are some issues with numpy multiarray in 3.7
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install Dependencies
run: |
python -m pip install --upgrade pip
pip install numba
pip install tensorflow>=2.0.0
pip install torch
pip install sigpy
pip install --upgrade simpleitk
make dev
pip install -e '.[dev]'
- name: Install Elastix
run: |
wget https://github.com/SuperElastix/elastix/releases/download/4.9.0/elastix-4.9.0-linux.tar.bz2
ELASTIX_FOLDER="elastix"
mkdir -p $ELASTIX_FOLDER
tar -xvf elastix-4.9.0-linux.tar.bz2 -C $ELASTIX_FOLDER
ELASTIX_DIR="$(realpath $ELASTIX_FOLDER)"
echo "PATH=${ELASTIX_DIR}/bin:${PATH}" >> $GITHUB_ENV
echo "LD_LIBRARY_PATH=${ELASTIX_DIR}/lib:${LD_LIBRARY_PATH}" >> $GITHUB_ENV
- name: Test with pytest
run: |
pip install pytest
pip install pytest-cov
make test-cov
- name: Upload to codecov.io
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository
uses: codecov/codecov-action@v1
with:
file: ./coverage.xml
flags: unittests
name: codecov-umbrella
fail_ci_if_error: true