# PyTorch GPU runtime FROM pytorch/pytorch:2.1.0-cuda11.8-cudnn8-runtime # Set working directory WORKDIR /app # Copy requirements COPY requirements.txt . # Install dependencies RUN pip install --upgrade pip && \ pip install --no-cache-dir -r requirements.txt # Copy project files COPY . . # Hugging Face Spaces port EXPOSE 7860 # Run FastAPI CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]