Add attention ablation: MHA vs MQA vs GQA vs FlashAttention on perple… #6
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: CI | |
| on: | |
| push: | |
| branches: [main, dev] | |
| pull_request: | |
| branches: [main] | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| lint: | |
| name: Lint (black + isort) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.10" | |
| - name: Install linters | |
| run: pip install black isort | |
| - name: black check | |
| run: black --check --diff . --exclude '/(\.git|__pycache__)/' || true | |
| - name: isort check | |
| run: isort --check-only --diff . || true | |
| test: | |
| name: Build & Test (A30, SM86) | |
| runs-on: [self-hosted, gpu, sm86] | |
| needs: lint | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install deps | |
| run: pip install torch==2.2.0 triton==2.2.0 ninja packaging pytest tabulate | |
| - name: Build CUDA extension | |
| run: TORCH_CUDA_ARCH_LIST="8.6" pip install -e . --no-build-isolation | |
| - name: Run tests | |
| run: pytest tests/test_correctness.py -v |