This repository has been archived by the owner on Nov 1, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 78
117 lines (106 loc) · 3.38 KB
/
rc-wheel-build.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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
name: TorchArrow RC Build and Test
on:
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
linux-container:
runs-on: ubuntu-latest
container: prestocpp/velox-sse-velox-torcharrow:kpai-20220711
strategy:
fail-fast: false
matrix:
python-version:
- 3.7
- 3.8
- 3.9
- "3.10"
steps:
- name: Check out source repository
uses: actions/checkout@v2
with:
ref: "release/0.1.0"
submodules: recursive
- name: Build the wheel
run: |
pip3 install --upgrade pip
source /opt/conda/etc/profile.d/conda.sh
PYTHON_VERSION=${{ matrix.python-version }} CPU_TARGET="sse" packaging/build_wheel.sh
conda activate env${{ matrix.python-version }}
pip3 install auditwheel
auditwheel repair dist/*.whl -w fixed_dist --plat manylinux2014_x86_64
- name: Install and Test TorchArrow Wheel
shell: bash
env:
PYTHON_VERSION: ${{ matrix.python-version }}
run: |
source packaging/manylinux/python_helper.sh
pip3 install fixed_dist/torcharrow*.whl
pip3 install pytest
pip3 install torch
pytest -v torcharrow/test/integration
- name: Upload Wheels to Github
uses: actions/upload-artifact@v2
with:
name: torcharrow-artifact
path: fixed_dist/torcharrow*.whl
- name: Upload Official Wheels to PYPI
env:
PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
run: |
pip3 install setuptools-rust
pip3 install twine
twine upload \
--username __token__ \
--password "$PYPI_TOKEN" \
fixed_dist/torcharrow*.whl
macos-container:
runs-on: macos-latest
strategy:
fail-fast: false
matrix:
python-version:
- 3.7
- 3.8
- 3.9
- "3.10"
steps:
- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Check out source repository
uses: actions/checkout@v2
with:
ref: "release/0.1.0"
submodules: recursive
- name: Build the wheel
run: |
pip3 install --upgrade pip
MACOSX_DEPLOYMENT_TARGET=10.15 CPU_TARGET="sse" ./csrc/velox/velox/scripts/setup-macos.sh
pip install wheel
CPU_TARGET="sse" ./packaging/build_wheel.sh
pip install delocate
delocate-wheel dist/*.whl -w fixed_dist
- name: Install and Test TorchArrow Wheel
shell: bash
env:
PYTHON_VERSION: ${{ matrix.python-version }}
run: |
pip3 install fixed_dist/torcharrow*.whl
pip3 install pytest
pip3 install torch
pytest -v torcharrow/test/integration
- name: Upload Wheels to Github
uses: actions/upload-artifact@v2
with:
name: torcharrow-artifact
path: fixed_dist/torcharrow*.whl
- name: Upload Official Wheels to PYPI
env:
PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
run: |
pip3 install twine
twine upload \
--username __token__ \
--password "$PYPI_TOKEN" \
fixed_dist/torcharrow*.whl