|
|
FROM python:3.10-slim |
|
|
|
|
|
WORKDIR /app |
|
|
|
|
|
|
|
|
RUN apt-get update && apt-get install -y \ |
|
|
git git-lfs ffmpeg libsm6 libxext6 libgl1 curl \ |
|
|
build-essential cmake ninja-build \ |
|
|
&& rm -rf /var/lib/apt/lists/* \ |
|
|
&& git lfs install |
|
|
|
|
|
|
|
|
RUN pip install --no-cache-dir torch==2.0.1 torchvision==0.15.2 |
|
|
|
|
|
|
|
|
RUN pip install --no-cache-dir git+https://github.com/facebookresearch/detectron2.git |
|
|
|
|
|
|
|
|
RUN pip install --no-cache-dir \ |
|
|
gradio>=4.0.0 \ |
|
|
opencv-python-headless \ |
|
|
"numpy<2" \ |
|
|
Pillow \ |
|
|
fvcore \ |
|
|
iopath \ |
|
|
pyyaml \ |
|
|
tqdm \ |
|
|
huggingface_hub |
|
|
|
|
|
COPY . /app |
|
|
|
|
|
EXPOSE 7860 |
|
|
|
|
|
CMD ["python", "app.py"] |