Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
norm
vllm
Commits
5255d99d
Unverified
Commit
5255d99d
authored
Feb 15, 2024
by
Hongxia Yang
Committed by
GitHub
Feb 15, 2024
Browse files
[ROCm] Dockerfile fix for flash-attention build (#2885)
parent
4f2ad111
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
Dockerfile.rocm
Dockerfile.rocm
+3
-3
No files found.
Dockerfile.rocm
View file @
5255d99d
...
@@ -56,10 +56,10 @@ ENV LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/rocm/lib/:/libtorch/lib:
...
@@ -56,10 +56,10 @@ ENV LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/rocm/lib/:/libtorch/lib:
ENV CPLUS_INCLUDE_PATH=$CPLUS_INCLUDE_PATH:/libtorch/include:/libtorch/include/torch/csrc/api/include/:/opt/rocm/include/:
ENV CPLUS_INCLUDE_PATH=$CPLUS_INCLUDE_PATH:/libtorch/include:/libtorch/include/torch/csrc/api/include/:/opt/rocm/include/:
# Install ROCm flash-attention
# Install ROCm flash-attention
RUN if [ "$BUILD_FA" =
=
"1" ]; then \
RUN if [ "$BUILD_FA" = "1" ]; then \
mkdir libs \
mkdir libs \
&& cd libs \
&& cd libs \
&& git clone https://github.com/ROCm
SoftwarePlatform
/flash-attention.git \
&& git clone https://github.com/ROCm/flash-attention.git \
&& cd flash-attention \
&& cd flash-attention \
&& git checkout ${FA_BRANCH} \
&& git checkout ${FA_BRANCH} \
&& git submodule update --init \
&& git submodule update --init \
...
@@ -83,7 +83,7 @@ RUN if [ "$BASE_IMAGE" = "rocm/pytorch:rocm6.0_ubuntu20.04_py3.9_pytorch_2.1.1"
...
@@ -83,7 +83,7 @@ RUN if [ "$BASE_IMAGE" = "rocm/pytorch:rocm6.0_ubuntu20.04_py3.9_pytorch_2.1.1"
RUN cd /app \
RUN cd /app \
&& cd vllm \
&& cd vllm \
&& pip install -U -r requirements-rocm.txt \
&& pip install -U -r requirements-rocm.txt \
&& if [ "$BUILD_FA" =
=
"1" ]; then \
&& if [ "$BUILD_FA" = "1" ]; then \
bash patch_xformers.rocm.sh; fi \
bash patch_xformers.rocm.sh; fi \
&& patch /opt/rocm/include/hip/amd_detail/amd_hip_bf16.h /app/vllm/rocm_patch/rocm_bf16.patch \
&& patch /opt/rocm/include/hip/amd_detail/amd_hip_bf16.h /app/vllm/rocm_patch/rocm_bf16.patch \
&& python3 setup.py install \
&& python3 setup.py install \
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment