Skip to content

Commit

Permalink
Auto: clean up interrogators (AbdBarho#265)
Browse files Browse the repository at this point in the history
  • Loading branch information
AbdBarho committed Dec 17, 2022
1 parent 5a9d305 commit 41e0dcc
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 10 deletions.
1 change: 1 addition & 0 deletions data/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
/RealESRGAN
/SwinIR
/MiDaS
/BLIP
/ScuNET
/LDSR
/Deepdanbooru
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ services:
<<: *base_service
profiles: ["auto"]
build: ./services/AUTOMATIC1111
image: sd-auto:22
image: sd-auto:23
environment:
- CLI_ARGS=--allow-code --medvram --xformers --enable-insecure-extension-access --api

Expand Down
15 changes: 7 additions & 8 deletions services/AUTOMATIC1111/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,11 @@ ENV ROOT=/stable-diffusion-webui

COPY --from=download /git/ ${ROOT}
RUN mkdir ${ROOT}/interrogate && cp ${ROOT}/repositories/clip-interrogator/data/* ${ROOT}/interrogate
RUN pip install -r ${ROOT}/repositories/CodeFormer/requirements.txt
RUN --mount=type=cache,target=/root/.cache/pip \
pip install -r ${ROOT}/repositories/CodeFormer/requirements.txt


ARG DEEPDANBOORU="0"
RUN [[ "${DEEPDANBOORU:-0}" == "0" ]] && : || pip install tensorflow-cpu==2.10 tensorflow-io==0.27.0 git+https://github.com/KichangKim/DeepDanbooru.git@edf73df4cdaeea2cf00e9ac08bd8a9026b7a7b26#egg=deepdanbooru

RUN pip install opencv-python-headless \
RUN --mount=type=cache,target=/root/.cache/pip \
pip install opencv-python-headless \
git+https://github.com/TencentARC/GFPGAN.git@8d2447a2d918f8eba5a4a01463fd48e45126a379 \
git+https://github.com/openai/CLIP.git@d50d76daa670286dd6cacf3bcd80b5e4823fc8e1 \
git+https://github.com/mlfoundations/open_clip.git@bb6e834e9c70d9c27d0dc3ecedeebeaeb1ffad6b \
Expand All @@ -72,14 +70,15 @@ RUN pip install opencv-python-headless \
# instead, update the repo state in a later step

ARG SHA=685f9631b56ff8bd43bce24ff5ce0f9a0e9af490
RUN <<EOF
RUN --mount=type=cache,target=/root/.cache/pip <<EOF
cd stable-diffusion-webui
git fetch
git reset --hard ${SHA}
pip install -r requirements_versions.txt
EOF

RUN pip install opencv-python-headless transformers==4.24.0
RUN --mount=type=cache,target=/root/.cache/pip \
pip install opencv-python-headless transformers==4.24

COPY . /docker

Expand Down
3 changes: 2 additions & 1 deletion services/AUTOMATIC1111/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ MOUNTS["${ROOT}/models/SwinIR"]="/data/SwinIR"
MOUNTS["${ROOT}/models/ScuNET"]="/data/ScuNET"
MOUNTS["${ROOT}/models/LDSR"]="/data/LDSR"
MOUNTS["${ROOT}/models/hypernetworks"]="/data/Hypernetworks"
MOUNTS["${ROOT}/models/deepbooru"]="/data/Deepdanbooru"
MOUNTS["${ROOT}/models/torch_deepdanbooru"]="/data/Deepdanbooru"
MOUNTS["${ROOT}/models/BLIP"]="/data/BLIP"
MOUNTS["${ROOT}/models/midas"]="/data/MiDaS"

MOUNTS["${ROOT}/embeddings"]="/data/embeddings"
Expand Down

0 comments on commit 41e0dcc

Please sign in to comment.