-
Notifications
You must be signed in to change notification settings - Fork 487
/
Dockerfile_amd
35 lines (27 loc) · 1.13 KB
/
Dockerfile_amd
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
# Build with: `docker build -f Dockerfile_amd -t autogptq-rocm .`
# Run with: `docker run --rm -it --shm-size=150G --device /dev/kfd --device /dev/dri --net host --group-add=video --ipc=host --cap-add=SYS_PTRACE --security-opt seccomp=unconfined autogptq-rocm:latest /bin/bash`
FROM rocm/dev-ubuntu-22.04:5.7
RUN apt update && \
apt install -y wget \
git \
rocsparse-dev \
hipsparse-dev \
rocthrust-dev \
rocblas-dev \
hipblas-dev && \
apt clean && \
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
ENV PATH="/root/miniconda3/bin:${PATH}"
ARG PATH="/root/miniconda3/bin:${PATH}"
RUN wget \
https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh \
&& mkdir .conda \
&& bash Miniconda3-latest-Linux-x86_64.sh -b \
&& rm -f Miniconda3-latest-Linux-x86_64.sh
RUN conda init bash
RUN pip install --upgrade pip
RUN pip install --upgrade numpy setuptools wheel ninja packaging
RUN pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/rocm5.7
RUN git clone https://github.com/AutoGPTQ/AutoGPTQ.git
WORKDIR /AutoGPTQ
RUN ROCM_VERSION="5.7" pip install -vvv .