CoolFace
Apppublic

Ajaykumar10/Automatic_Number_Plate_Recognition_ANPR_System

sourceHugging Faceupdated 5mo agoView on Hugging Face
0likes
Dockerfile39 linesDownload Raw Back to root
1# HuggingFace Spaces Dockerfile2FROM python:3.10-slim3 4# Install system dependencies for OpenCV5RUN apt-get update && apt-get install -y \6    libgl1-mesa-glx \7    libglib2.0-0 \8    libsm6 \9    libxext6 \10    libxrender-dev \11    libgomp1 \12    && rm -rf /var/lib/apt/lists/*13 14# Set working directory15WORKDIR /app16 17# Copy requirements first (for Docker layer caching)18COPY requirements.txt .19 20# Install Python dependencies21RUN pip install --no-cache-dir -r requirements.txt22 23# Copy all project files24COPY . .25 26# ── KEY FIX ──27# Pre-download EasyOCR models at BUILD TIME so the app28# doesn't need internet access at runtime (fixes 30min timeout)29RUN python download_models.py30 31# Expose Gradio port32EXPOSE 786033 34# Set environment variable to suppress Ultralytics config warning35ENV YOLO_CONFIG_DIR=/tmp/Ultralytics36 37# Run the app38CMD ["python", "app.py"]39