fix memory issue on windows runner

- use cpu version which is only 162.6 MB
- set `INVOKEAI_ROOT=C:\InvokeAI` on Windows runners
This commit is contained in:
mauwii 2023-01-17 06:14:54 +01:00
parent 5a788f8f73
commit 963b666844
No known key found for this signature in database
GPG Key ID: D923DB04ADB3F5AB

View File

@ -3,6 +3,7 @@ on:
push:
branches:
- 'main'
- 'debug/dev/pyproject-toml'
pull_request:
types:
- 'ready_for_review'
@ -28,8 +29,8 @@ jobs:
- linux-rocm-5_2
# - linux-cpu
- macos-default
# - windows-cpu
- windows-cuda-11_7
- windows-cpu
# - windows-cuda-11_7
include:
- pytorch: linux-cuda-11_7
os: ubuntu-22.04
@ -41,38 +42,34 @@ jobs:
# - pytorch: linux-cpu
# os: ubuntu-22.04
# extra-index-url: 'https://download.pytorch.org/whl/cpu'
# github-env: $GITHUB_ENV
- pytorch: macos-default
os: macOS-12
github-env: $GITHUB_ENV
# - pytorch: windows-cpu
# os: windows-2022
- pytorch: windows-cuda-11_7
- pytorch: windows-cpu
os: windows-2022
extra-index-url: 'https://download.pytorch.org/whl/cu117'
github-env: $env:GITHUB_ENV
# - pytorch: windows-cuda-11_7
# os: windows-2022
# extra-index-url: 'https://download.pytorch.org/whl/cu117'
# github-env: $env:GITHUB_ENV
name: ${{ matrix.pytorch }} on ${{ matrix.python-version }}
runs-on: ${{ matrix.os }}
env:
INVOKEAI_ROOT: ${{ github.workspace }}
INVOKE_MODEL_RECONFIGURE: '--yes'
INVOKEAI_ROOT: '${{ github.workspace }}/invokeai'
PYTHONUNBUFFERED: 1
HAVE_SECRETS: ${{ secrets.HUGGINGFACE_TOKEN != '' }}
steps:
- name: Checkout sources
id: checkout-sources
uses: actions/checkout@v3
- name: set INVOKEAI_ROOT Windows
if: matrix.os == 'windows-2022'
if: runner.os == 'Windows'
run: |
echo "INVOKEAI_ROOT=${{ github.workspace }}\invokeai" >> ${{ matrix.github-env }}
echo "INVOKEAI_OUTDIR=${{ github.workspace }}\invokeai\outputs" >> ${{ matrix.github-env }}
- name: set INVOKEAI_ROOT others
if: matrix.os != 'windows-2022'
run: |
echo "INVOKEAI_ROOT=${{ github.workspace }}/invokeai" >> ${{ matrix.github-env }}
echo "INVOKEAI_OUTDIR=${{ github.workspace }}/invokeai/outputs" >> ${{ matrix.github-env }}
Get-PSDrive
mkdir C:\InvokeAI
echo "INVOKEAI_ROOT=C:\InvokeAI" >> ${{ matrix.github-env }}
- name: Use Cached diffusers-1.5
id: cache-sd-model
@ -120,7 +117,7 @@ jobs:
- name: Run the tests
id: run-tests
if: matrix.os != 'windows-2022'
if: runner.os != 'Windows'
env:
# Set offline mode to make sure configure preloaded successfully.
HF_HUB_OFFLINE: 1
@ -133,11 +130,10 @@ jobs:
--model ${{ matrix.stable-diffusion-model }}
--from_file ${{ env.TEST_PROMPTS }}
--root="${{ env.INVOKEAI_ROOT }}"
--outdir="${{ env.INVOKEAI_OUTDIR }}"
- name: Archive results
id: archive-results
if: matrix.os != 'windows-2022'
if: runner.os != 'Windows'
uses: actions/upload-artifact@v3
with:
name: results_${{ matrix.pytorch }}_${{ matrix.python-version }}