File size: 818 Bytes
f5765c8 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 |
FROM nvidia/cuda:12.3.2-cudnn9-devel-ubuntu22.04
# Set environment variables
ENV DEBIAN_FRONTEND=noninteractive
ENV PYTHONUNBUFFERED=1
ENV FLASH_ATTENTION_SKIP_CUDA_BUILD=TRUE
# Install system dependencies
RUN apt-get update && apt-get install -y \
python3.10 \
python3-pip \
python3.10-dev \
build-essential \
ninja-build \
git \
&& rm -rf /var/lib/apt/lists/*
# Create and set working directory
WORKDIR /app
# Copy requirements first to leverage Docker cache
COPY requirements.txt .
# Install Python dependencies
RUN pip3 install --no-cache-dir -r requirements.txt
# Install flash-attention
RUN pip3 install --no-cache-dir flash-attn --no-build-isolation
# Copy the rest of the application
COPY . .
# Set the default command
CMD ["python3", "-m", "src.video_processor.processor"] |