Upload folder using huggingface_hub
Browse files- Dockerfile +42 -0
Dockerfile
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# 1. ๋ฒ ์ด์ค ์ด๋ฏธ์ง๋ฅผ CUDA 12.4๋ก ์ง์
|
| 2 |
+
FROM nvidia/cuda:12.4.1-devel-ubuntu22.04
|
| 3 |
+
|
| 4 |
+
ENV DEBIAN_FRONTEND=noninteractive
|
| 5 |
+
|
| 6 |
+
RUN apt-get update && apt-get install -y \
|
| 7 |
+
python3.10 \
|
| 8 |
+
python3.10-dev \
|
| 9 |
+
python3-pip \
|
| 10 |
+
git \
|
| 11 |
+
build-essential \
|
| 12 |
+
cmake \
|
| 13 |
+
ninja-build \
|
| 14 |
+
&& rm -rf /var/lib/apt/lists/*
|
| 15 |
+
|
| 16 |
+
RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.10 1
|
| 17 |
+
RUN python3 -m pip install --upgrade pip
|
| 18 |
+
|
| 19 |
+
WORKDIR /app
|
| 20 |
+
COPY ./exllamav3 /app/exllamav3
|
| 21 |
+
|
| 22 |
+
# ------------------------------------------------------------------
|
| 23 |
+
# ๐ฅ ABI ๋ฏธ์ค๋งค์น๋ฅผ ์์ฒ ์ฐจ๋จํ๋ ๊ณต์ ํ๋ฆฌ๋น๋ ํ ๋์
|
| 24 |
+
# ------------------------------------------------------------------
|
| 25 |
+
|
| 26 |
+
# 1. ์ฃผ์ถง๋์ด ๋๋ ๊ณ ์ฑ๋ฅ CUDA 12.4์ฉ PyTorch ์ค์น
|
| 27 |
+
RUN pip install torch>=2.6.0 --index-url https://download.pytorch.org/whl/cu124
|
| 28 |
+
|
| 29 |
+
# 2. PyTorch 2.6 ํ๊ฒฝ๊ณผ 100% ์ผ์นํ๋ Flash-Attention ๊ณต์ ํ๋ฆฌ๋น๋ ํ ์ง์ ์ค์น
|
| 30 |
+
RUN pip install https://github.com/Dao-AILab/flash-attention/releases/download/v2.7.4.post1/flash_attn-2.7.4.post1%2Bcu12torch2.6cxx11abiFALSE-cp310-cp310-linux_x86_64.whl
|
| 31 |
+
|
| 32 |
+
# 3. ๋๋จธ์ง ํจํค์ง ์ค์น
|
| 33 |
+
RUN pip install -r /app/exllamav3/requirements.txt --extra-index-url https://download.pytorch.org/whl/cu124
|
| 34 |
+
|
| 35 |
+
# 4. ์ต์ข
exllamav3 ๋ผ์ด๋ธ๋ฌ๋ฆฌ ๋น๋
|
| 36 |
+
RUN pip install /app/exllamav3
|
| 37 |
+
|
| 38 |
+
# ------------------------------------------------------------------
|
| 39 |
+
# ๐ EXL3 Resume(์์
์ฌ๊ฐ) ์ ์ฉ ์ํธ๋ฆฌํฌ์ธํธ ์ค์
|
| 40 |
+
# ------------------------------------------------------------------
|
| 41 |
+
# -i, -o, -b ์ต์
์ ์ ๊ฑฐํ๊ณ ์ํน ๋๋ ํ ๋ฆฌ ์ง์ ๋ฐ -r(--resume) ์ธ์๋ง ๋ช
์ํฉ๋๋ค.
|
| 42 |
+
CMD ["python3", "/app/exllamav3/convert.py", "-w", "/workspace/work", "-r"]
|