|
|
|
|
|
|
|
|
|
|
|
FROM nvidia/cuda:12.1.1-devel-ubuntu22.04 |
|
|
|
|
|
|
|
|
ENV DEBIAN_FRONTEND=noninteractive |
|
|
RUN apt-get update && apt-get install -y --no-install-recommends \ |
|
|
wget \ |
|
|
git \ |
|
|
&& apt-get clean \ |
|
|
&& rm -rf /var/lib/apt/lists/* |
|
|
|
|
|
|
|
|
RUN wget --quiet https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda.sh && \ |
|
|
/bin/bash ~/miniconda.sh -b -p /opt/conda && \ |
|
|
rm ~/miniconda.sh |
|
|
|
|
|
|
|
|
ENV PATH /opt/conda/bin:$PATH |
|
|
|
|
|
|
|
|
COPY . /app |
|
|
WORKDIR /app |
|
|
|
|
|
|
|
|
RUN yes | conda tos accept |
|
|
|
|
|
|
|
|
RUN conda update -n base -c defaults conda |
|
|
|
|
|
|
|
|
RUN conda env create -f environment.yml && conda clean --all -y |
|
|
|
|
|
|
|
|
RUN conda run -n seedvr env FLASH_ATTENTION_SKIP_CUDA_BUILD=TRUE \ |
|
|
pip install "flash_attn==2.5.9.post1" --no-build-isolation --no-cache-dir |
|
|
|
|
|
|
|
|
WORKDIR /app/SeedVR |
|
|
RUN huggingface-cli download ByteDance-Seed/SeedVR2-3B --local-dir ckpts --local-dir-use-symlinks False |
|
|
|
|
|
|
|
|
WORKDIR /app |
|
|
CMD ["conda", "run", "-n", "seedvr", "uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"] |