Dovakiins commited on
Commit
65c38b0
1 Parent(s): fa92474

Upload Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +38 -0
Dockerfile ADDED
@@ -0,0 +1,38 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ARG BASE_TAG=main-base
2
+ FROM winglian/axolotl-base:$BASE_TAG
3
+
4
+ ARG TORCH_CUDA_ARCH_LIST="7.0 7.5 8.0 8.6+PTX"
5
+ ARG AXOLOTL_EXTRAS=""
6
+ ARG AXOLOTL_ARGS=""
7
+ ARG CUDA="118"
8
+ ENV BNB_CUDA_VERSION=$CUDA
9
+ ARG PYTORCH_VERSION="2.1.2"
10
+
11
+ ENV PYTORCH_VERSION=$PYTORCH_VERSION
12
+
13
+ RUN apt-get update && \
14
+ apt-get install -y --allow-change-held-packages vim curl nano libnccl2 libnccl-dev rsync s3fs
15
+
16
+ WORKDIR /workspace
17
+
18
+ RUN git clone --depth=1 https://github.com/OpenAccess-AI-Collective/axolotl.git
19
+
20
+ WORKDIR /workspace/axolotl
21
+
22
+ # If AXOLOTL_EXTRAS is set, append it in brackets
23
+ RUN pip install causal_conv1d
24
+ RUN if [ "$AXOLOTL_EXTRAS" != "" ] ; then \
25
+ pip install -e .[deepspeed,flash-attn,mamba-ssm,galore,$AXOLOTL_EXTRAS] $AXOLOTL_ARGS; \
26
+ else \
27
+ pip install -e .[deepspeed,flash-attn,mamba-ssm,galore] $AXOLOTL_ARGS; \
28
+ fi
29
+
30
+ # So we can test the Docker image
31
+ RUN pip install pytest
32
+
33
+ # fix so that git fetch/pull from remote works
34
+ RUN git config remote.origin.fetch "+refs/heads/*:refs/remotes/origin/*" && \
35
+ git config --get remote.origin.fetch
36
+
37
+ # helper for huggingface-login cli
38
+ RUN git config --global credential.helper store