Full hub mixin integration (#179) #257
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: API CUDA Tests | |
on: | |
workflow_dispatch: | |
push: | |
branches: [main] | |
pull_request: | |
types: [opened, reopened, synchronize] | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
run_api_cuda_tests: | |
runs-on: [single-gpu, nvidia-gpu, a10, ci] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Pull image | |
run: docker pull pytorch/pytorch:2.2.2-cuda12.1-cudnn8-runtime | |
- name: Run tests | |
uses: addnab/docker-run-action@v3 | |
env: | |
HF_TOKEN: ${{ secrets.HF_TOKEN }} | |
with: | |
image: pytorch/pytorch:2.2.2-cuda12.1-cudnn8-runtime | |
options: | | |
--rm | |
--gpus all | |
--shm-size 64G | |
--env HF_TOKEN | |
--env MKL_THREADING_LAYER=GNU | |
--volume ${{ github.workspace }}:/workspace | |
--workdir /workspace | |
run: | | |
pip install -e .[testing,timm,diffusers] | |
huggingface-cli login --token $HF_TOKEN | |
pytest -s -x -k "api and cuda" |