ai_platform_cv/Dockerfile

21 lines
781 B
Docker
Raw Permalink Normal View History

2022-12-07 10:46:43 +08:00
FROM pytorch/pytorch:1.12.0-cuda11.3-cudnn8-runtime
2022-08-03 10:16:48 +08:00
WORKDIR /app
2022-12-07 10:46:43 +08:00
ADD ./requirements.txt /app/
2022-08-03 10:16:48 +08:00
RUN pip install --upgrade pip -i https://pypi.tuna.tsinghua.edu.cn/simple --no-cache-dir
2022-12-07 10:46:43 +08:00
# RUN pip install torch torchvision --extra-index-url https://download.pytorch.org/whl/cu113 --no-cache-dir
2022-08-03 10:16:48 +08:00
RUN pip install -r requirements.txt -i https://pypi.tuna.tsinghua.edu.cn/simple --no-cache-dir
RUN mim install mmcv-full
2022-12-07 10:46:43 +08:00
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
2022-08-03 10:16:48 +08:00
CMD ["python3", "run.py"]