forked from jllllll/llama-cpp-python-cuBLAS-wheels
-
Notifications
You must be signed in to change notification settings - Fork 1
59 lines (53 loc) · 1.7 KB
/
build-wheels-batch-rocm.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
name: Batch Build ROCm Wheels
on:
workflow_dispatch:
inputs:
versions:
description: 'Comma-seperated version tags of llama-cpp-python to build'
default: 'v0.2.18,v0.2.17,v0.2.16,v0.2.15,v0.2.14'
required: true
type: string
config:
description: 'Override configurations to build: key1:item1-1,item1-2;key2:item2-1,item2-2'
default: 'Default'
required: false
type: string
exclude:
description: 'Exclude build configurations: key1-1:item1-1,key1-2:item1-2;key2-1:item2-1,key2-2:item2-2'
default: 'Default'
required: false
type: string
permissions:
contents: write
jobs:
define_matrix:
name: Define Workflow Matrix
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
defaults:
run:
shell: pwsh
env:
PCKGVERS: ${{ inputs.versions }}
steps:
- uses: actions/checkout@v4
- name: Define Job Output
id: set-matrix
run: |
$versions = $env:PCKGVERS.Split(',').Trim()
$versions.foreach({if ([version]$_.TrimStart('v') -lt [version]'0.1.80') {Throw "$_ does not support ROCm!"}})
$x = ConvertTo-Json $versions -Compress
Write-Output ('matrix=' + $x) >> $env:GITHUB_OUTPUT
run_workflows:
name: Build ${{ matrix.version }} Wheels
needs: define_matrix
strategy:
max-parallel: 1
matrix:
version: ${{ fromJSON(needs.define_matrix.outputs.matrix) }}
uses: ./.github/workflows/build-wheels-rocm-full.yml
with:
version: ${{ matrix.version }}
config: ${{ inputs.config }}
exclude: ${{ inputs.exclude }}