[WIP] Continue work on Integration with DeepLabCut 3.0 #296
This file contains hidden or 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: Run Tests | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| jobs: | |
| build: | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| python-version: ["3.10"] | |
| include: | |
| - os: ubuntu-latest | |
| path: ~/.cache/pip | |
| - os: macos-latest | |
| path: ~/Library/Caches/pip | |
| - os: windows-latest | |
| path: ~\AppData\Local\pip\Cache | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Set up Python | |
| uses: conda-incubator/setup-miniconda@v3 | |
| with: | |
| channels: conda-forge,defaults | |
| channel-priority: strict | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install ffmpeg | |
| run: | | |
| if [ "$RUNNER_OS" == "Linux" ]; then | |
| sudo apt-get update | |
| sudo apt-get install ffmpeg | |
| elif [ "$RUNNER_OS" == "macOS" ]; then | |
| brew install ffmpeg | |
| else | |
| choco install ffmpeg | |
| fi | |
| shell: bash | |
| - name: Install and test | |
| shell: bash -el {0} # Important: activates the conda environment | |
| run: | | |
| conda install pytables==3.8.0 "numpy<2" | |
| - name: Install dependencies via Conda | |
| shell: bash -el {0} | |
| run: conda install -y "numpy>=1.26,<2.0" | |
| - name: Install Poetry | |
| run: pip install --upgrade pip wheel poetry | |
| - name: Regenerate Poetry lock | |
| run: poetry lock --no-cache | |
| - name: Install project dependencies | |
| run: poetry install --with dev --extras "tf" --extras "pytorch" | |
| - name: Run DLC Live Tests | |
| run: poetry run dlc-live-test --nodisplay | |
| - name: Run Functional Benchmark Test | |
| run: poetry run pytest tests/test_benchmark_script.py |