name: Build Xformers on: workflow_dispatch: {} jobs: build: runs-on: ubuntu-latest timeout-minutes: 180 container: image: python:3.10-slim env: DEBIAN_FRONTEND: noninteractive XFORMERS_DISABLE_FLASH_ATTN: 1 FORCE_CUDA: 1 TORCH_CUDA_ARCH_LIST: "6.0;6.1;6.2;7.0;7.2;7.5;8.0;8.6" NVCC_FLAGS: --use_fast_math -DXFORMERS_MEM_EFF_ATTENTION_DISABLE_BACKWARD MAX_JOBS: 4 steps: - run: | apt-get update apt-get install gpg wget git -y wget https://developer.download.nvidia.com/compute/cuda/repos/debian11/x86_64/cuda-keyring_1.0-1_all.deb dpkg -i cuda-keyring_1.0-1_all.deb apt-get update apt-get install cuda-nvcc-11-8 cuda-libraries-dev-11-8 -y export PIP_CACHE_DIR=$(pwd)/cache 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@3633e1afc7bffbe61957f04e7bb1a742ee910ace#egg=xformers - name: Artifacts uses: actions/upload-artifact@v3 with: name: xformers path: data/xformers-0.0.14.dev0-cp310-cp310-linux_x86_64.whl