Skip to content

Commit

Permalink
test: CI convert llama3.1
Browse files Browse the repository at this point in the history
  • Loading branch information
nguyenhoangthuan99 committed Aug 11, 2024
1 parent d37afb9 commit 20ab726
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions .github/workflows/convert-model.yml
Original file line number Diff line number Diff line change
Expand Up @@ -100,10 +100,15 @@ jobs:
# mkdir -p C:\\models\\$${{ env.MODEL_NAME }}/hf
# mkdir -p C:\\models\\$${{ env.MODEL_NAME }}/onnx
# mkdir -p C:\\models\\$${{ env.MODEL_NAME }}/cache

- name: Check file existence
id: check_files
uses: andstor/file-existence-action@v1
with:
files: "C:\models\${{ env.MODEL_NAME }}/hf"

- name: Download Hugging Face model
if: ${{ hashFiles("C:\models\${{ env.MODEL_NAME }}/hf") != '' }}
id: download_hf
if: steps.check_files.outputs.files_exists == 'true'
run: |
mkdir -p C:\models\${{ env.MODEL_NAME }}/hf
mkdir -p C:\models\${{ env.MODEL_NAME }}/onnx
Expand All @@ -112,6 +117,11 @@ jobs:
huggingface-cli download --repo-type model --local-dir ${{ env.MODEL_NAME }}/hf ${{ env.SOURCE_MODEL_ID }}
huggingface-cli logout
- name: Rollback Deployment
if: steps.download_hf.outcome == 'failure'
run: |
Remove-Item -Recurse -Force -Path "$C:\models\{{ env.MODEL_NAME }}"
# - name: Cache Hugging Face model
# uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
# with:
Expand Down

0 comments on commit 20ab726

Please sign in to comment.