From 34f4011a6bedadee49aed2eeb466d602db0f057d Mon Sep 17 00:00:00 2001 From: SOULOFCINDER <841135647@qq.com> Date: Thu, 6 Apr 2023 17:14:08 +0800 Subject: [PATCH] update --- full_body_anime_gan/Dockerfile | 13 +++++++++++-- full_body_anime_gan/anime-seg | 1 - full_body_anime_gan/fbanime-gan | 1 - full_body_anime_gan/packages.txt | 2 ++ full_body_anime_gan/requirements.txt | 3 ++- 5 files changed, 15 insertions(+), 5 deletions(-) delete mode 160000 full_body_anime_gan/anime-seg delete mode 160000 full_body_anime_gan/fbanime-gan create mode 100644 full_body_anime_gan/packages.txt diff --git a/full_body_anime_gan/Dockerfile b/full_body_anime_gan/Dockerfile index 6eb73f7..7d4e68f 100644 --- a/full_body_anime_gan/Dockerfile +++ b/full_body_anime_gan/Dockerfile @@ -2,10 +2,15 @@ FROM public.ecr.aws/iflytek-open/cuda-go-python-base:11.6-1.17-3.9.13-ubuntu1804 +RUN sed -i 's@//.*archive.ubuntu.com@//mirrors.ustc.edu.cn@g' /etc/apt/sources.list +RUN sed -i 's/security.ubuntu.com/mirrors.ustc.edu.cn/g' /etc/apt/sources.list + +RUN --mount=target=/root/packages.txt,source=packages.txt apt-get update && xargs -r -a /root/packages.txt apt-get install -y && rm -rf /var/lib/apt/lists/* WORKDIR /home/user/app RUN useradd -m -u 1000 user -RUN chown -R 1000.1000 /home/userF +RUN chown -R 1000.1000 /home/user + RUN pip config set global.index-url https://pypi.mirrors.ustc.edu.cn/simple/ @@ -13,8 +18,12 @@ RUN pip config set global.index-url https://pypi.mirrors.ustc.edu.cn/simple/ RUN pip install --no-cache-dir pip==22.3.1 RUN --mount=target=requirements.txt,source=requirements.txt pip install --no-cache-dir -r requirements.txt - COPY --chown=1000 ./ /home/user/app +RUN curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | bash +RUN apt-get install git-lfs +RUN git lfs install +RUN git https://huggingface.co/skytnt/fbanime-gan +RUN git https://huggingface.co/skytnt/anime-seg CMD ["python3", "app.py"] \ No newline at end of file diff --git a/full_body_anime_gan/anime-seg b/full_body_anime_gan/anime-seg deleted file mode 160000 index a0a563c..0000000 --- a/full_body_anime_gan/anime-seg +++ /dev/null @@ -1 +0,0 @@ -Subproject commit a0a563c41338cbe0d23dfb4bfc3e243c518e5768 diff --git a/full_body_anime_gan/fbanime-gan b/full_body_anime_gan/fbanime-gan deleted file mode 160000 index 79c6af6..0000000 --- a/full_body_anime_gan/fbanime-gan +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 79c6af6b789fb18533eb9885fc21680ee29d235e diff --git a/full_body_anime_gan/packages.txt b/full_body_anime_gan/packages.txt new file mode 100644 index 0000000..b399c93 --- /dev/null +++ b/full_body_anime_gan/packages.txt @@ -0,0 +1,2 @@ +git +curl \ No newline at end of file diff --git a/full_body_anime_gan/requirements.txt b/full_body_anime_gan/requirements.txt index 5d7191b..148f214 100644 --- a/full_body_anime_gan/requirements.txt +++ b/full_body_anime_gan/requirements.txt @@ -2,4 +2,5 @@ gradio onnx onnxruntime-gpu scikit-image -imageio-ffmpeg \ No newline at end of file +imageio-ffmpeg +torch \ No newline at end of file