Add kilosort4 wrapper tests #30
Workflow file for this run
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
name: Testing Kilosort4 | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: "0 12 * * 0" # Weekly on Sunday at noon UTC | |
pull_request: | |
types: [synchronize, opened, reopened] | |
branches: | |
- main | |
# env: | |
# KACHERY_CLOUD_CLIENT_ID: ${{ secrets.KACHERY_CLOUD_CLIENT_ID }} | |
# KACHERY_CLOUD_PRIVATE_KEY: ${{ secrets.KACHERY_CLOUD_PRIVATE_KEY }} | |
# concurrency: # Cancel previous workflows on the same pull request | |
# group: ${{ github.workflow }}-${{ github.ref }} | |
# cancel-in-progress: true | |
jobs: | |
fetch-versions: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.12 | |
- name: Install dependencies | |
run: | | |
pip install requests | |
- name: Fetch package versions from PyPI | |
run: | | |
python .github/scripts/check_kilosort4_releases.py | |
echo $(pwd) | |
pwd | |
ls .github/scripts | |
echo ${{ github.workspace }} | |
shell: bash | |
- name: Upload versions file | |
uses: actions/upload-artifact@v2 | |
with: | |
name: versions | |
path: ${{ github.workspace }}/.github/scripts/kilosort4-latest-version.json | |
configure: | |
needs: fetch-versions | |
runs-on: ubuntu-latest | |
outputs: | |
matrix: ${{ steps.set-matrix.outputs.matrix }} | |
steps: | |
- name: Checkout to repository | |
uses: actions/checkout@v2 | |
- name: Set matrix data | |
id: set-matrix | |
run: | | |
pwd | |
ls .github/scripts | |
ls | |
echo "matrix=$(jq -c . < ${{ github.workspace }}/.github/scripts/kilosort4-latest-version.json)" >> $GITHUB_OUTPUT | |
test: | |
needs: configure | |
name: ${{ matrix.os }} Python ${{ matrix.python-version }} | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ["3.12"] # TODO: "3.9", # Lower and higher versions we support | |
os: [ubuntu-latest] # TODO: macos-13, windows-latest, | |
ks_version: ${{ fromJson(needs.configure.outputs.matrix) }} # TODO: add / build from pypi based on Christians PR | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install packages | |
# TODO: maybe dont need full? | |
run: | | |
pip install -e .[test] | |
# git config --global user.email "[email protected]" | |
# git config --global user.name "CI Almighty" | |
# pip install tabulate | |
shell: bash | |
- name: Install Kilosort | |
run: | | |
pip install kilosort==${{ matrix.ks_version }} | |
shell: bash | |
- name: Run new kilosort4 tests | |
# run: chmod +x .github/test_kilosort4.sh | |
# TODO: figure out the paths to be able to run this by calling the file directly | |
run: | | |
pytest -k test_kilosort4_new --durations=0 | |
shell: bash | |
# TODO: pip install -e .[full,dev] is failing # | |
#The conflict is caused by: | |
# spikeinterface[docs] 0.101.0rc0 depends on datalad==0.16.2; extra == "docs" | |
# spikeinterface[test] 0.101.0rc0 depends on datalad>=1.0.2; extra == "test" |