Skip to content

add simplified MPRAGE model #18

add simplified MPRAGE model

add simplified MPRAGE model #18

Workflow file for this run

name: CI-CD
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.11, 3.12] # Specify the desired Python versions
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
pip install .[test]
- name: Run tests
run: pytest --cov --cov-report=xml tests
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4.0.1
with:
token: ${{ secrets.CODECOV_TOKEN }}
slug: INFN-MRI/torchsim
docs:
runs-on: ubuntu-20.04
needs: test
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Restore cached IXI directory
uses: actions/cache/restore@v4
id: cache-restore
with:
path: ~/.ixi
key: ${{ runner.os }}-ixi
- name: Install dependencies
shell: bash -l {0}
run: |
python -m pip install --upgrade pip
python -m pip install .[doc]
python -m pip install -r docs/requirements.txt
- name: Build API documentation
run: |
python -m sphinx docs docs_build
- name: Display structure of docs
run: ls -R docs_build/
- name: Cache IXI directory
uses: actions/cache/save@v4
if: ${{ steps.cache-restore.outputs.cache-hit != 'true' }}
with:
path: ~/.ixi
key: ${{ runner.os }}-ixi
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs_build
destination_dir: . # Ensure you deploy to the root of the gh-pages branch
publish_branch: gh-pages
keep_files: false