Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
# π Use official Python | |
FROM python:3.11-slim | |
ENV TRANSFORMERS_CACHE=/tmp | |
ENV HF_HOME=/tmp | |
# Install wget | |
RUN apt-get update && apt-get install -y wget | |
WORKDIR /app | |
COPY . . | |
RUN mkdir -p vit_captioning/artifacts && \ | |
wget https://huggingface.co/datasets/ClemSummer/clip-checkpoints/resolve/main/CLIPEncoder_40epochs_unfreeze12.pth \ | |
-O vit_captioning/artifacts/CLIPEncoder_40epochs_unfreeze12.pth | |
RUN pip install --upgrade pip | |
RUN pip install -r requirements.txt | |
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"] |