KangjieXu commited on
Commit
a79a628
·
verified ·
1 Parent(s): dca385b

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +22 -15
Dockerfile CHANGED
@@ -1,15 +1,22 @@
1
- FROM python:3.10-slim
2
-
3
- WORKDIR /app
4
-
5
- # 安装底层系统依赖(RDKit 和 编译工具)
6
- RUN apt-get update && apt-get install -y \
7
- git \
8
- git-lfs \
9
- build-essential \
10
- libgl1 \
11
- libglib2.0-0 \
12
- && rm -rf /var/lib/apt/lists/*
13
-
14
- # 锁定 NumPy 1.x Torch 2.4.1 (CPU版)
15
- RUN pip install --no-cache-dir "numpy<2"
 
 
 
 
 
 
 
 
1
+ FROM python:3.10-slim
2
+
3
+ WORKDIR /app
4
+
5
+ # 安装必要的系统库 (这对 RDKit 和其他底层计算库至关重要)
6
+ RUN apt-get update && apt-get install -y \
7
+ git \
8
+ git-lfs \
9
+ build-essential \
10
+ libgl1 \
11
+ libglib2.0-0 \
12
+ && rm -rf /var/lib/apt/lists/*
13
+
14
+ # 安装 PyTorch CPU 版本 (如果你用 GPU Space,请改用对应的 CUDA )
15
+ RUN pip install --no-cache-dir "numpy<2" "torch==2.4.1" --index-url https://download.pytorch.org/whl/cpu
16
+
17
+ COPY requirements.txt .
18
+ RUN pip install --no-cache-dir -r requirements.txt
19
+
20
+ COPY . .
21
+
22
+ CMD ["python", "app.py"]