forked from prisect/vde
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
39 lines (25 loc) · 868 Bytes
/
Copy pathDockerfile
File metadata and controls
39 lines (25 loc) · 868 Bytes
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
35
36
37
38
FROM nvidia/cuda:11.8.0-cudnn8-runtime-ubuntu20.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y \
python3.9 \
python3.9-dev \
python3.9-distutils \
python3-pip \
python3.9-venv \
libgl1-mesa-glx \
build-essential \
&& apt-get clean
RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.9 1
RUN python3 -m pip install --upgrade pip setuptools
RUN python3 -m pip install virtualenv
RUN python3 -m venv /env
RUN pip install --no-cache-dir \
torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118 \
numpy pillow
RUN pip install --no-cache-dir scikit-learn --index-url https://pypi.org/simple
WORKDIR /app
COPY . /app
RUN mkdir -p /app/samples
RUN mkdir -p /app/weights
RUN ln -sf /usr/bin/python3 /usr/bin/python
CMD ["python3", "main.py"]