lucky0146 commited on
Commit
ef536c5
·
verified ·
1 Parent(s): 330421d

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +12 -6
Dockerfile CHANGED
@@ -1,19 +1,25 @@
1
  FROM python:3.10-slim
2
 
3
- # System dependencies (minimal set)
4
  RUN apt-get update && apt-get install -y \
 
 
5
  libopenblas-dev \
6
  libx11-dev \
7
  libgl1-mesa-glx \
 
 
 
 
8
  && rm -rf /var/lib/apt/lists/*
9
 
10
- # Install pre-built dlib wheel (no compilation needed)
 
11
  RUN pip install --upgrade pip && \
12
- pip install https://files.pythonhosted.org/packages/0e/ce/f8a3cff33ac03a8219768f0694c5d703c8e037e6aba2e865f9bae22ed63c/dlib-19.24.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
13
 
14
- # Install remaining Python dependencies
15
- COPY requirements.txt .
16
- RUN pip install --no-cache-dir -r requirements.txt
17
 
18
  # Clone CodeFormer
19
  RUN git clone https://github.com/sczhou/CodeFormer
 
1
  FROM python:3.10-slim
2
 
3
+ # System dependencies for dlib and OpenCV
4
  RUN apt-get update && apt-get install -y \
5
+ cmake \
6
+ build-essential \
7
  libopenblas-dev \
8
  libx11-dev \
9
  libgl1-mesa-glx \
10
+ libjpeg-dev \
11
+ zlib1g-dev \
12
+ git \
13
+ wget \
14
  && rm -rf /var/lib/apt/lists/*
15
 
16
+ # Install core Python dependencies first
17
+ COPY requirements.txt .
18
  RUN pip install --upgrade pip && \
19
+ pip install --no-cache-dir -r requirements.txt
20
 
21
+ # Install dlib with optimized CPU build
22
+ RUN pip install dlib==19.24.1 --no-binary :all:
 
23
 
24
  # Clone CodeFormer
25
  RUN git clone https://github.com/sczhou/CodeFormer