Unverified Commit 433f0b22 authored by Muyang Li's avatar Muyang Li Committed by GitHub
Browse files

chore: support torch 2.9 uploading wheel to hf (#598)

* chore: support uploading wheel to hf

* support ready_for_review
parent 2327c994
name: PR Tests name: PR Tests
on: on:
pull_request: pull_request:
types: [opened, synchronize, reopened] types: [opened, synchronize, reopened, ready_for_review]
paths: paths:
- "nunchaku/**" - "nunchaku/**"
- "src/**" - "src/**"
...@@ -98,8 +98,8 @@ jobs: ...@@ -98,8 +98,8 @@ jobs:
comfy node install comfyui-inpainteasy comfy node install comfyui-inpainteasy
cp -r custom_nodes/ComfyUI-nunchaku/tests nunchaku_tests cp -r custom_nodes/ComfyUI-nunchaku/tests nunchaku_tests
pip install -r nunchaku_tests/requirements.txt pip install -r nunchaku_tests/requirements.txt
HF_TOKEN=${{ secrets.HF_TOKEN }} python custom_nodes/ComfyUI-nunchaku/scripts/download_models.py python custom_nodes/ComfyUI-nunchaku/scripts/download_models.py
HF_TOKEN=${{ secrets.HF_TOKEN }} python custom_nodes/ComfyUI-nunchaku/scripts/download_test_data.py python custom_nodes/ComfyUI-nunchaku/scripts/download_test_data.py
- name: Run ComfyUI tests - name: Run ComfyUI tests
run: | run: |
source $(conda info --base)/etc/profile.d/conda.sh source $(conda info --base)/etc/profile.d/conda.sh
......
...@@ -51,7 +51,7 @@ jobs: ...@@ -51,7 +51,7 @@ jobs:
strategy: strategy:
matrix: matrix:
python: ["3.10", "3.11", "3.12"] python: ["3.10", "3.11", "3.12"]
torch: ["2.5", "2.6", "2.7", "2.8"] torch: ["2.5", "2.6", "2.7", "2.8", "2.9"]
steps: steps:
- name: Checkout to the tag - name: Checkout to the tag
uses: actions/checkout@v4 uses: actions/checkout@v4
...@@ -82,6 +82,18 @@ jobs: ...@@ -82,6 +82,18 @@ jobs:
prerelease: false prerelease: false
env: env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Upload wheels to HuggingFace Hub
env:
HF_TOKEN: ${{ secrets.HF_WHEEL_UPLOAD_TOKEN }}
run: |
pip install huggingface_hub
for whl in dist/*.whl; do
hf upload nunchaku-tech/nunchaku "$whl" .
done
- name: Clean up - name: Clean up
if: always() if: always()
run: bash scripts/linux_cleanup.sh run: bash scripts/linux_cleanup.sh
...@@ -92,7 +104,7 @@ jobs: ...@@ -92,7 +104,7 @@ jobs:
strategy: strategy:
matrix: matrix:
python: ["3.10", "3.11", "3.12"] python: ["3.10", "3.11", "3.12"]
torch: ["2.5", "2.6", "2.7", "2.8"] torch: ["2.5", "2.6", "2.7", "2.8", "2.9"]
steps: steps:
- name: Checkout to the tag - name: Checkout to the tag
uses: actions/checkout@v4 uses: actions/checkout@v4
...@@ -129,3 +141,16 @@ jobs: ...@@ -129,3 +141,16 @@ jobs:
prerelease: false prerelease: false
env: env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Upload wheels to HuggingFace Hub
shell: cmd
env:
HF_TOKEN: ${{ secrets.HF_WHEEL_UPLOAD_TOKEN }}
run: |
pip install huggingface_hub
for %%w in (dist\*.whl) do (
hf upload nunchaku-tech/nunchaku "%%w" .
)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment