layoutlmv2-base-uncased/Dockerfile

20 lines
463 B
Docker

FROM python:3.8.13
WORKDIR /app
COPY . /app
RUN pip config set global.index-url https://pypi.mirrors.ustc.edu.cn/simple
RUN sed -i 's/deb.debian.org/mirrors.ustc.edu.cn/g' /etc/apt/sources.list
ENV PYHTONUNBUFFERED=1
RUN apt-get update && apt-get -y install tesseract-ocr
RUN pip install pyyaml==5.1
RUN pip install -r requirements.txt
RUN pip install 'git+https://ghproxy.com/https://github.com/facebookresearch/detectron2.git'
CMD ["python", "app.py"]