Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Docker environment & web demo #67

Merged
merged 8 commits into from
Aug 29, 2022
Merged

Conversation

chenxwh
Copy link
Contributor

@chenxwh chenxwh commented Sep 17, 2021

Hey @xinntao ! 👋

Appreciated your feedback on the previous PR. It has been modified accordingly in this PR.

This pull request makes it possible to run your model inside a Docker environment, which makes it easier for other people to run it. We're using an open source tool called Cog to make this process easier.

This also means we can make a web page where other people can try out your model! View it here: https://replicate.ai/xinntao/gfpgan
(We noticed that you have a demo on Gradio, but some of the example images, e.g. 10045.png, would show error there).

Claim your page here so you can edit it, and we'll feature it on our website and tweet about it too.

In case you're wondering who I am, I'm from Replicate, where we're trying to make machine learning reproducible. We got frustrated that we couldn't run all the really interesting ML work being done. So, we're going round implementing models we like. 😊

@chenxwh chenxwh changed the title Replicate Add Docker environment & web demo Sep 17, 2021
@chenxwh
Copy link
Contributor Author

chenxwh commented Oct 19, 2021

Hello again @xinntao :),

Thank your for your previous feedback on the original PR, it has been updated accordingly. Also we are very happy that you have claimed the page, it already has +1100 runs. If you are happy to merge the PR then we can also feature your model on our homepage and more people can view and try it. Curious what you think.

Thank you :)

@marcellodesales
Copy link

marcellodesales commented Dec 28, 2021

No Dockerfile

  • I don't see anything in this PR :)
  • To me, Docker environment is when I can do docker-compose up --build

As an Engineer who depends on Docker, I don't think this is it... Maybe rename the PR to something else? It's just misleading...

It's only my 2c

Edit

This is a Dockerized solution #103

@chenxwh
Copy link
Contributor Author

chenxwh commented Dec 28, 2021

No Dockerfile

  • I don't see anything in this PR :)

  • To me, Docker environment is when I can do docker-compose up --build

As an Engineer who depends on Docker, I don't think this is it... Maybe rename the PR to something else? It's just misleading...

It's only my 2c

Edit

This is a Dockerized solution #103

You can find the docker file under 'Run model with Docker' tab https://replicate.com/xinntao/gfpgan

Cog is built on top of Docker.

@marcellodesales
Copy link

marcellodesales commented Dec 28, 2021

@cjwbw I'm inspecting the contents of your image at r8.im/xinntao/gfpgan@sha256:fec8c51c3017f1afbf8b0eed7f4ba51158e49b527b92aea91833aed32559e2ef, and here's so far what I've gathered...

  • I couldn't find the original Dockerfile for the image at the URL above...

Docker image contents

$ docker pull r8.im/xinntao/gfpgan@sha256:fec8c51c3017f1afbf8b0eed7f4ba51158e49b527b92aea91833aed32559e2ef
r8.im/xinntao/gfpgan@sha256:fec8c51c3017f1afbf8b0eed7f4ba51158e49b527b92aea91833aed32559e2ef: Pulling from xinntao/gfpgan
be8ec4e48d7f: Pull complete
33b8b485aff0: Pull complete
d887158cc58c: Pull complete
05895bb28c18: Pull complete
3d2964768f60: Pull complete
879de1f9d3b9: Pull complete
4e56b74a6bb6: Pull complete
b6074c21aee0: Downloading [===========>                                       ]  337.9MB/1.501GB
ef6ce9582f59: Downloading [============>                                      ]  318.4MB/1.232GB
ab542382d70b: Downloading [==========>                                        ]  316.3MB/1.568GB
8e6b9d4be9a9: Waiting
930d70c29689: Waiting
879de1f9d3b9: Pull complete
4e56b74a6bb6: Pull complete
b6074c21aee0: Extracting [=================================>                 ]  1.008GB/1.501GB
ef6ce9582f59: Download complete
ab542382d70b: Download complete
8e6b9d4be9a9: Download complete
930d70c29689: Download complete
7f289d2e276d: Download complete
337893cc1f37: Download complete
0bb517c37c6e: Download complete
5771a13f4df1: Downloading [=====>                                             ]  244.9MB/2.127GB
a2f81b718912: Download complete
5fa8dd99e2d2: Downloading [============================================>      ]  77.28MB/86.89MB
5dcc5424fc83: Download complete
789491982219: Downloading [==>                                                ]  19.97MB/335.6MB

Edit

This is the biggest Docker Image EVER: 15.3GB :) Well, I guess this is necessary and let me organize my thoughts on the next comment... :)

$ docker images | grep r8.im/xinntao/gfpgan
r8.im/xinntao/gfpgan                                           <none>                                                  ff65bbeab0fe   4 months ago        15.3GB

$ docker history ff65bbeab0fe
IMAGE          CREATED         CREATED BY                                      SIZE      COMMENT
ff65bbeab0fe   4 months ago    /bin/sh -c #(nop)  LABEL org.cogmodel.type_s…   0B
<missing>      4 months ago    COPY . /src # buildkit                          367MB     buildkit.dockerfile.v0
<missing>      4 months ago    LABEL org.cogmodel.config={"build":{"gpu":tr…   0B        buildkit.dockerfile.v0
<missing>      4 months ago    LABEL org.cogmodel.cog_version=0.0.8            0B        buildkit.dockerfile.v0
<missing>      4 months ago    CMD ["python" "-m" "cog.server.http"]           0B        buildkit.dockerfile.v0
<missing>      4 months ago    WORKDIR /src                                    0B        buildkit.dockerfile.v0
<missing>      4 months ago    RUN /bin/sh -c pip install realesrgan # buil…   186MB     buildkit.dockerfile.v0
<missing>      4 months ago    RUN /bin/sh -c pip install facexlib==0.2.0.2…   384MB     buildkit.dockerfile.v0
<missing>      4 months ago    RUN /bin/sh -c pip install -f https://downlo…   4.53GB    buildkit.dockerfile.v0
<missing>      4 months ago    RUN /bin/sh -c apt-get update -qq && apt-get…   85.8MB    buildkit.dockerfile.v0
<missing>      4 months ago    RUN /bin/sh -c pip install /tmp/cog-0.0.1.de…   9.27MB    buildkit.dockerfile.v0
<missing>      4 months ago    COPY .cog/tmp/cog-0.0.1.dev-py3-none-any.whl…   13.4kB    buildkit.dockerfile.v0
<missing>      4 months ago    RUN /bin/sh -c curl https://pyenv.run | bash…   218MB     buildkit.dockerfile.v0
<missing>      4 months ago    RUN /bin/sh -c apt-get update -qq && apt-get…   164MB     buildkit.dockerfile.v0
<missing>      4 months ago    ENV PATH=/root/.pyenv/shims:/root/.pyenv/bin…   0B        buildkit.dockerfile.v0
<missing>      4 months ago    ENV LD_LIBRARY_PATH=/usr/local/nvidia/lib:/u…   0B        buildkit.dockerfile.v0
<missing>      4 months ago    ENV PYTHONUNBUFFERED=1                          0B        buildkit.dockerfile.v0
<missing>      4 months ago    ENV DEBIAN_FRONTEND=noninteractive              0B        buildkit.dockerfile.v0
<missing>      12 months ago   RUN /bin/sh -c apt-get update && apt-get ins…   4.57GB    buildkit.dockerfile.v0
<missing>      12 months ago   LABEL com.nvidia.cudnn.version=8.0.5.39         0B        buildkit.dockerfile.v0
<missing>      12 months ago   ENV CUDNN_VERSION=8.0.5.39                      0B        buildkit.dockerfile.v0
<missing>      12 months ago   LABEL maintainer=NVIDIA CORPORATION <cudatoo…   0B        buildkit.dockerfile.v0
<missing>      12 months ago   ENV LIBRARY_PATH=/usr/local/cuda/lib64/stubs    0B        buildkit.dockerfile.v0
<missing>      12 months ago   RUN /bin/sh -c apt-get update && apt-get ins…   2.22GB    buildkit.dockerfile.v0
<missing>      12 months ago   ENV NCCL_VERSION=2.7.8                          0B        buildkit.dockerfile.v0
<missing>      12 months ago   LABEL maintainer=NVIDIA CORPORATION <cudatoo…   0B        buildkit.dockerfile.v0
<missing>      12 months ago   RUN /bin/sh -c apt-get update && apt-get ins…   2.39GB    buildkit.dockerfile.v0
<missing>      12 months ago   ENV NCCL_VERSION=2.7.8                          0B        buildkit.dockerfile.v0
<missing>      12 months ago   LABEL maintainer=NVIDIA CORPORATION <cudatoo…   0B        buildkit.dockerfile.v0
<missing>      12 months ago   ENV NVIDIA_REQUIRE_CUDA=cuda>=11.1 brand=tes…   0B        buildkit.dockerfile.v0
<missing>      12 months ago   ENV NVIDIA_DRIVER_CAPABILITIES=compute,utili…   0B        buildkit.dockerfile.v0
<missing>      12 months ago   ENV NVIDIA_VISIBLE_DEVICES=all                  0B        buildkit.dockerfile.v0
<missing>      12 months ago   ENV LD_LIBRARY_PATH=/usr/local/nvidia/lib:/u…   0B        buildkit.dockerfile.v0
<missing>      12 months ago   ENV PATH=/usr/local/nvidia/bin:/usr/local/cu…   0B        buildkit.dockerfile.v0
<missing>      12 months ago   RUN /bin/sh -c echo "/usr/local/nvidia/lib" …   46B       buildkit.dockerfile.v0
<missing>      12 months ago   RUN /bin/sh -c apt-get update && apt-get ins…   32.6MB    buildkit.dockerfile.v0
<missing>      12 months ago   ENV CUDA_VERSION=11.1.1                         0B        buildkit.dockerfile.v0
<missing>      12 months ago   RUN /bin/sh -c apt-get update && apt-get ins…   15.9MB    buildkit.dockerfile.v0
<missing>      12 months ago   LABEL maintainer=NVIDIA CORPORATION <cudatoo…   0B        buildkit.dockerfile.v0
<missing>      13 months ago   /bin/sh -c #(nop)  CMD ["/bin/bash"]            0B
<missing>      13 months ago   /bin/sh -c mkdir -p /run/systemd && echo 'do…   7B
<missing>      13 months ago   /bin/sh -c rm -rf /var/lib/apt/lists/*          0B
<missing>      13 months ago   /bin/sh -c set -xe   && echo '#!/bin/sh' > /…   745B
<missing>      13 months ago   /bin/sh -c #(nop) ADD file:8eef54430e581236e…   131MB

Dockerfile needed

$ docker history --human --no-trunc ff65bbeab0fe
IMAGE                                                                     CREATED         CREATED BY                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 SIZE      COMMENT
sha256:ff65bbeab0fed02f5726b07e3345cde94b2c9cc7832bb15e61936393c4f4f020   4 months ago    /bin/sh -c #(nop)  LABEL org.cogmodel.type_signature={"inputs":[{"name":"image","type":"Path","help":"input image"}]}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      0B
<missing>                                                                 4 months ago    COPY . /src # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     367MB     buildkit.dockerfile.v0
<missing>                                                                 4 months ago    LABEL org.cogmodel.config={"build":{"gpu":true,"python_version":"3.8","python_packages":["torch==1.8.0","torchvision==0.9.0","numpy==1.21.1","ipython==7.21.0","lmdb==1.2.1","opencv-python==4.5.3.56","PyYAML==5.4.1","tqdm==4.62.2","yapf==0.31.0","tb-nightly==2.7.0a20210825"],"system_packages":["libgl1-mesa-glx","libglib2.0-0"],"pre_install":["pip install facexlib==0.2.0.2","pip install realesrgan"],"cuda":"11.1","cudnn":"8"},"predict":"predict.py:Predictor"}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              0B        buildkit.dockerfile.v0
<missing>                                                                 4 months ago    LABEL org.cogmodel.cog_version=0.0.8                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       0B        buildkit.dockerfile.v0
<missing>                                                                 4 months ago    CMD ["python" "-m" "cog.server.http"]                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      0B        buildkit.dockerfile.v0
<missing>                                                                 4 months ago    WORKDIR /src                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               0B        buildkit.dockerfile.v0
<missing>                                                                 4 months ago    RUN /bin/sh -c pip install realesrgan # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           186MB     buildkit.dockerfile.v0
<missing>                                                                 4 months ago    RUN /bin/sh -c pip install facexlib==0.2.0.2 # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    384MB     buildkit.dockerfile.v0
<missing>                                                                 4 months ago    RUN /bin/sh -c pip install -f https://download.pytorch.org/whl/torch_stable.html   torch==1.8.0+cu111 torchvision==0.9.0+cu111 numpy==1.21.1 ipython==7.21.0 lmdb==1.2.1 opencv-python==4.5.3.56 PyYAML==5.4.1 tqdm==4.62.2 yapf==0.31.0 tb-nightly==2.7.0a20210825 # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             4.53GB    buildkit.dockerfile.v0
<missing>                                                                 4 months ago    RUN /bin/sh -c apt-get update -qq && apt-get install -qqy libgl1-mesa-glx libglib2.0-0 && rm -rf /var/lib/apt/lists/* # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           85.8MB    buildkit.dockerfile.v0
<missing>                                                                 4 months ago    RUN /bin/sh -c pip install /tmp/cog-0.0.1.dev-py3-none-any.whl # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  9.27MB    buildkit.dockerfile.v0
<missing>                                                                 4 months ago    COPY .cog/tmp/cog-0.0.1.dev-py3-none-any.whl /tmp/cog-0.0.1.dev-py3-none-any.whl # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                13.4kB    buildkit.dockerfile.v0
<missing>                                                                 4 months ago    RUN /bin/sh -c curl https://pyenv.run | bash &&  git clone https://github.com/momo-lab/pyenv-install-latest.git "$(pyenv root)"/plugins/pyenv-install-latest &&  pyenv install-latest "3.8" &&  pyenv global $(pyenv install-latest --print "3.8") # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              218MB     buildkit.dockerfile.v0
<missing>                                                                 4 months ago    RUN /bin/sh -c apt-get update -qq && apt-get install -qqy --no-install-recommends  make  build-essential  libssl-dev  zlib1g-dev  libbz2-dev  libreadline-dev  libsqlite3-dev  wget  curl  llvm  libncurses5-dev  libncursesw5-dev  xz-utils  tk-dev  libffi-dev  liblzma-dev  python-openssl  git  ca-certificates  && rm -rf /var/lib/apt/lists/* # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             164MB     buildkit.dockerfile.v0
<missing>                                                                 4 months ago    ENV PATH=/root/.pyenv/shims:/root/.pyenv/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        0B        buildkit.dockerfile.v0
<missing>                                                                 4 months ago    ENV LD_LIBRARY_PATH=/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/usr/lib/x86_64-linux-gnu:/usr/local/nvidia/lib64:/usr/local/nvidia/bin                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  0B        buildkit.dockerfile.v0
<missing>                                                                 4 months ago    ENV PYTHONUNBUFFERED=1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     0B        buildkit.dockerfile.v0
<missing>                                                                 4 months ago    ENV DEBIAN_FRONTEND=noninteractive                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   RUN /bin/sh -c apt-get update && apt-get install -y --no-install-recommends     libcudnn8=$CUDNN_VERSION-1+cuda11.1     libcudnn8-dev=$CUDNN_VERSION-1+cuda11.1     && apt-mark hold libcudnn8 &&     rm -rf /var/lib/apt/lists/* # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               4.57GB    buildkit.dockerfile.v0
<missing>                                                                 12 months ago   LABEL com.nvidia.cudnn.version=8.0.5.39                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   ENV CUDNN_VERSION=8.0.5.39                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   LABEL maintainer=NVIDIA CORPORATION <[email protected]>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   ENV LIBRARY_PATH=/usr/local/cuda/lib64/stubs                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   RUN /bin/sh -c apt-get update && apt-get install -y --no-install-recommends     cuda-nvml-dev-11-1=11.1.74-1     cuda-command-line-tools-11-1=11.1.1-1     cuda-nvprof-11-1=11.1.105-1     libnpp-dev-11-1=11.1.2.301-1     cuda-libraries-dev-11-1=11.1.1-1     cuda-minimal-build-11-1=11.1.1-1     libnccl-dev=2.7.8-1+cuda11.1     libcublas-dev-11-1=11.3.0.106-1     libcusparse-11-1=11.3.0.10-1     libcusparse-dev-11-1=11.3.0.10-1     && apt-mark hold libnccl-dev     && rm -rf /var/lib/apt/lists/* # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2.22GB    buildkit.dockerfile.v0
<missing>                                                                 12 months ago   ENV NCCL_VERSION=2.7.8                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   LABEL maintainer=NVIDIA CORPORATION <[email protected]>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   RUN /bin/sh -c apt-get update && apt-get install -y --no-install-recommends     cuda-libraries-11-1=11.1.1-1     libnpp-11-1=11.1.2.301-1     cuda-nvtx-11-1=11.1.74-1     libcublas-11-1=11.3.0.106-1     libnccl2=$NCCL_VERSION-1+cuda11.1     && apt-mark hold libnccl2     && rm -rf /var/lib/apt/lists/* # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   2.39GB    buildkit.dockerfile.v0
<missing>                                                                 12 months ago   ENV NCCL_VERSION=2.7.8                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   LABEL maintainer=NVIDIA CORPORATION <[email protected]>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   ENV NVIDIA_REQUIRE_CUDA=cuda>=11.1 brand=tesla,driver>=418,driver<419 brand=tesla,driver>=440,driver<441 brand=tesla,driver>=450,driver<451                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   ENV NVIDIA_DRIVER_CAPABILITIES=compute,utility                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   ENV NVIDIA_VISIBLE_DEVICES=all                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   ENV LD_LIBRARY_PATH=/usr/local/nvidia/lib:/usr/local/nvidia/lib64                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   ENV PATH=/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   RUN /bin/sh -c echo "/usr/local/nvidia/lib" >> /etc/ld.so.conf.d/nvidia.conf &&     echo "/usr/local/nvidia/lib64" >> /etc/ld.so.conf.d/nvidia.conf # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             46B       buildkit.dockerfile.v0
<missing>                                                                 12 months ago   RUN /bin/sh -c apt-get update && apt-get install -y --no-install-recommends     cuda-cudart-11-1=11.1.74-1     cuda-compat-11-1     && ln -s cuda-11.1 /usr/local/cuda &&     rm -rf /var/lib/apt/lists/* # buildkit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       32.6MB    buildkit.dockerfile.v0
<missing>                                                                 12 months ago   ENV CUDA_VERSION=11.1.1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    0B        buildkit.dockerfile.v0
<missing>                                                                 12 months ago   RUN /bin/sh -c apt-get update && apt-get install -y --no-install-recommends     ca-certificates apt-transport-https gnupg-curl &&     NVIDIA_GPGKEY_SUM=d1be581509378368edeec8c1eb2958702feedf3bc3d17011adbf24efacce4ab5 &&     NVIDIA_GPGKEY_FPR=ae09fe4bbd223a84b2ccfce3f60f4b3d7fa2af80 &&     apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64/7fa2af80.pub &&     apt-key adv --export --no-emit-version -a $NVIDIA_GPGKEY_FPR | tail -n +5 > cudasign.pub &&     echo "$NVIDIA_GPGKEY_SUM  cudasign.pub" | sha256sum -c --strict - && rm cudasign.pub &&     echo "deb https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64 /" > /etc/apt/sources.list.d/cuda.list &&     echo "deb https://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1604/x86_64 /" > /etc/apt/sources.list.d/nvidia-ml.list &&     apt-get purge --auto-remove -y gnupg-curl     && rm -rf /var/lib/apt/lists/* # buildkit                                                                                                                                                                       15.9MB    buildkit.dockerfile.v0
<missing>                                                                 12 months ago   LABEL maintainer=NVIDIA CORPORATION <[email protected]>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 0B        buildkit.dockerfile.v0
<missing>                                                                 13 months ago   /bin/sh -c #(nop)  CMD ["/bin/bash"]                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       0B
<missing>                                                                 13 months ago   /bin/sh -c mkdir -p /run/systemd && echo 'docker' > /run/systemd/container                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 7B
<missing>                                                                 13 months ago   /bin/sh -c rm -rf /var/lib/apt/lists/*                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     0B
<missing>                                                                 13 months ago   /bin/sh -c set -xe   && echo '#!/bin/sh' > /usr/sbin/policy-rc.d  && echo 'exit 101' >> /usr/sbin/policy-rc.d  && chmod +x /usr/sbin/policy-rc.d   && dpkg-divert --local --rename --add /sbin/initctl  && cp -a /usr/sbin/policy-rc.d /sbin/initctl  && sed -i 's/^exit.*/exit 0/' /sbin/initctl   && echo 'force-unsafe-io' > /etc/dpkg/dpkg.cfg.d/docker-apt-speedup   && echo 'DPkg::Post-Invoke { "rm -f /var/cache/apt/archives/*.deb /var/cache/apt/archives/partial/*.deb /var/cache/apt/*.bin || true"; };' > /etc/apt/apt.conf.d/docker-clean  && echo 'APT::Update::Post-Invoke { "rm -f /var/cache/apt/archives/*.deb /var/cache/apt/archives/partial/*.deb /var/cache/apt/*.bin || true"; };' >> /etc/apt/apt.conf.d/docker-clean  && echo 'Dir::Cache::pkgcache ""; Dir::Cache::srcpkgcache "";' >> /etc/apt/apt.conf.d/docker-clean   && echo 'Acquire::Languages "none";' > /etc/apt/apt.conf.d/docker-no-languages   && echo 'Acquire::GzipIndexes "true"; Acquire::CompressionTypes::Order:: "gz";' > /etc/apt/apt.conf.d/docker-gzip-indexes   && echo 'Apt::AutoRemove::SuggestsImportant "false";' > /etc/apt/apt.conf.d/docker-autoremove-suggests   745B
<missing>                                                                 13 months ago   /bin/sh -c #(nop) ADD file:8eef54430e581236e6d529a7d09df648f43c840e889d9ae132e5ed25d7bd2b88 in /                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           131MB

@xinntao xinntao merged commit a9a2e3a into TencentARC:master Aug 29, 2022
@xinntao
Copy link
Member

xinntao commented Aug 29, 2022

@chenxwh
Sorry for the very late merge and reply :-)

May I know how can I update the demo in https://replicate.com/tencentarc/gfpgan?
Just modify the file in predict.py?

@chenxwh
Copy link
Contributor Author

chenxwh commented Aug 29, 2022

May I know how can I update the demo in https://replicate.com/tencentarc/gfpgan? Just modify the file in predict.py?

Hi @xinntao,

Sure! With cog login to you replicate account, and then cog push r8.im/tencentarc/gfpgan you can push any changes to the web page. Note that all the files including the weights should be in the directory when you do the push.

Sometimes it may be easier to pull the docker image already up for the demo and only make corresponding changes in predict.py, please refer to this for how it can be done.

More documentation about Cog can be found here.

Let me know if you need further clarification :)

@xinntao
Copy link
Member

xinntao commented Aug 31, 2022

May I know how can I update the demo in https://replicate.com/tencentarc/gfpgan? Just modify the file in predict.py?

Hi @xinntao,

Sure! With cog login to you replicate account, and then cog push r8.im/tencentarc/gfpgan you can push any changes to the web page. Note that all the files including the weights should be in the directory when you do the push.

Sometimes it may be easier to pull the docker image already up for the demo and only make corresponding changes in predict.py, please refer to this for how it can be done.

More documentation about Cog can be found here.

Let me know if you need further clarification :)

Hi @chenxwh

I have updated the replicate ai demo: https://replicate.com/tencentarc/gfpgan. And it has over 225,016 runs.
This PR has also been merged.
Can you help to feature the gfpgan model on your replicate.ai homepage and more people can view and try it?

@andreasjansson
Copy link

Hi @xinntao, Andreas from Replicate here. Really great work with GFPGAN, it's such a cool model! I've featured it on the home page.

If you'd like to chat in real-time, the Replicate Discord server is here: https://discord.gg/replicate. Would love to have you in our community!

@andreafalzetti
Copy link

andreafalzetti commented Aug 31, 2022

Why are there only v1.2 and v1.3 on Replciate? It would be helpful to try v1 too. Is it possible to add?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants