Add LoRA fine-tuning for PET #2001
Workflow file for this run
This file contains 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: Documentation | |
on: | |
push: | |
branches: [main] | |
tags: ["*"] | |
pull_request: | |
# Check all PR | |
jobs: | |
build: | |
permissions: | |
contents: write | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: setup Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: "3.12" | |
- name: install dependencies | |
run: python -m pip install tox | |
- name: build documentation | |
run: tox -e docs | |
env: | |
# Use the CPU-only version of torch | |
PIP_EXTRA_INDEX_URL: https://download.pytorch.org/whl/cpu | |
- name: put documentation in the website | |
run: | | |
git clone https://github.com/$GITHUB_REPOSITORY --branch gh-pages gh-pages | |
rm -rf gh-pages/.git | |
cd gh-pages | |
REF_KIND=$(echo $GITHUB_REF | cut -d / -f2) | |
if [[ "$REF_KIND" == "tags" ]]; then | |
TAG=${GITHUB_REF#refs/tags/} | |
mv ../docs/build/html $TAG | |
else | |
rm -rf latest | |
mv ../docs/build/html latest | |
fi | |
- name: deploy to gh-pages | |
if: github.event_name == 'push' | |
uses: peaceiris/actions-gh-pages@v4 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./gh-pages/ | |
force_orphan: true |