21 lines
781 B
Docker
21 lines
781 B
Docker
FROM pytorch/pytorch:1.12.0-cuda11.3-cudnn8-runtime
|
|
|
|
WORKDIR /app
|
|
ADD ./requirements.txt /app/
|
|
|
|
RUN pip install --upgrade pip -i https://pypi.tuna.tsinghua.edu.cn/simple --no-cache-dir
|
|
# RUN pip install torch torchvision --extra-index-url https://download.pytorch.org/whl/cu113 --no-cache-dir
|
|
RUN pip install -r requirements.txt -i https://pypi.tuna.tsinghua.edu.cn/simple --no-cache-dir
|
|
RUN mim install mmcv-full
|
|
|
|
ADD . /app
|
|
RUN pip install -e ./text2image/CLIP/ --no-cache-dir
|
|
RUN pip install -e ./backbone/mmpose/ --no-cache-dir
|
|
RUN pip install -e ./ocr/tr/ --no-cache-dir
|
|
# RUN rm -rf ./text2image/CLIP/
|
|
# RUN rm -rf ./ocr/tr/
|
|
# RUN rm -rf ./backbone/mmpose/
|
|
RUN pip uninstall opencv-python -y
|
|
RUN pip install opencv-python-headless --force-reinstall
|
|
|
|
CMD ["python3", "run.py"] |