From 125d91e2d253d0ef758227122a1bd31a41f229e0 Mon Sep 17 00:00:00 2001 From: AbdBarho Date: Fri, 14 Oct 2022 17:26:44 +0200 Subject: [PATCH] r --- .github/workflows/{docker.yml => xformers.yml} | 13 +++++-------- services/AUTOMATIC1111/Dockerfile | 9 ++------- 2 files changed, 7 insertions(+), 15 deletions(-) rename .github/workflows/{docker.yml => xformers.yml} (73%) diff --git a/.github/workflows/docker.yml b/.github/workflows/xformers.yml similarity index 73% rename from .github/workflows/docker.yml rename to .github/workflows/xformers.yml index 42cedcc..4db99b1 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/xformers.yml @@ -1,21 +1,18 @@ name: Build Xformers -on: [push] +on: + workflow_dispatch: {} jobs: build: runs-on: ubuntu-latest - # container: - # image: pytorch/manylinux-cuda113 container: image: python:3.10-slim env: DEBIAN_FRONTEND: noninteractive XFORMERS_DISABLE_FLASH_ATTN: 1 FORCE_CUDA: 1 - # TORCH_CUDA_ARCH_LIST: "3.7;5.0;5.2;6.0;6.1+PTX;7.0;7.5+PTX;8.0;8.6+PTX" - TORCH_CUDA_ARCH_LIST: "6.1" - NVCC_FLAGS: "--use_fast_math -DXFORMERS_MEM_EFF_ATTENTION_DISABLE_BACKWARD" + TORCH_CUDA_ARCH_LIST: "3.7;5.0;5.2;6.0;6.1+PTX;7.0;7.5+PTX;8.0;8.6+PTX" steps: - run: | apt-get update @@ -29,8 +26,8 @@ jobs: pip install ninja install torch --extra-index-url https://download.pytorch.org/whl/cu113 pip wheel --wheel-dir=data git+https://github.com/facebookresearch/xformers.git@ba93c5012d00bd1b010514a7bc9bd938c1ad6149#egg=xformers - - name: Archive production artifacts + - name: Artifacts uses: actions/upload-artifact@v3 with: - name: dist-without-markdown + name: xformers path: data/xformers-0.0.14.dev0-cp310-cp310-linux_x86_64.whl diff --git a/services/AUTOMATIC1111/Dockerfile b/services/AUTOMATIC1111/Dockerfile index 32e0ccf..9e855e7 100644 --- a/services/AUTOMATIC1111/Dockerfile +++ b/services/AUTOMATIC1111/Dockerfile @@ -20,12 +20,6 @@ EOF RUN git clone https://github.com/crowsonkb/k-diffusion.git repositories/k-diffusion && cd repositories/k-diffusion && git reset --hard f4e99857772fc3a126ba886aadf795a332774878 -# FROM pytorch/manylinux-cuda113 as xformers - -# RUN git clone https://github.com/facebookresearch/xformers /x -# WORKDIR /x -# ENV CU_VERSION=cu113 PYTHON_VERSION=3.10 PYTORCH_VERSION=1.12 -# RUN ./packaging/build_wheel.sh FROM python:3.10-slim @@ -72,7 +66,8 @@ RUN pip install --prefer-binary --no-cache-dir opencv-python-headless \ git+https://github.com/openai/CLIP.git@d50d76daa670286dd6cacf3bcd80b5e4823fc8e1 \ pyngrok -# COPY --from=xformers /x/wheels /wheels +COPY xformers-0.0.14.dev0-cp310-cp310-linux_x86_64.whl . +RUN pip install xformers-0.0.14.dev0-cp310-cp310-linux_x86_64.whl COPY . /docker RUN <