Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
c45d398e
Unverified
Commit
c45d398e
authored
Feb 08, 2025
by
Liangfu Chen
Committed by
GitHub
Feb 08, 2025
Browse files
[CI] Resolve transformers-neuronx version conflict (#12925)
parent
011e612d
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
11 deletions
+8
-11
.buildkite/run-neuron-test.sh
.buildkite/run-neuron-test.sh
+0
-3
Dockerfile.neuron
Dockerfile.neuron
+7
-1
requirements-neuron.txt
requirements-neuron.txt
+0
-1
setup.py
setup.py
+1
-6
No files found.
.buildkite/run-neuron-test.sh
View file @
c45d398e
...
...
@@ -29,9 +29,6 @@ if [ -f /tmp/neuron-docker-build-timestamp ]; then
docker image prune
-f
# Remove unused volumes / force the system prune for old images as well.
docker volume prune
-f
&&
docker system prune
-f
# Remove huggingface model artifacts and compiler cache
rm
-rf
"
${
HF_MOUNT
:?
}
/*"
rm
-rf
"
${
NEURON_COMPILE_CACHE_MOUNT
:?
}
/*"
echo
"
$current_time
"
>
/tmp/neuron-docker-build-timestamp
fi
else
...
...
Dockerfile.neuron
View file @
c45d398e
...
...
@@ -23,10 +23,12 @@ WORKDIR ${APP_MOUNT}/vllm
RUN python3 -m pip install --upgrade pip
RUN python3 -m pip install --no-cache-dir fastapi ninja tokenizers pandas
RUN python3 -m pip install sentencepiece transformers==4.45.2 -U
RUN python3 -m pip install transformers-neuronx --extra-index-url=https://pip.repos.neuron.amazonaws.com -U
RUN python3 -m pip install neuronx-cc==2.16.345.0 --extra-index-url=https://pip.repos.neuron.amazonaws.com -U
RUN python3 -m pip install pytest
# uninstall transformers-neuronx package explicitly to avoid version conflict
RUN python3 -m pip uninstall -y transformers-neuronx
COPY . .
ARG GIT_REPO_CHECK=0
RUN --mount=type=bind,source=.git,target=.git \
...
...
@@ -43,6 +45,10 @@ RUN --mount=type=bind,source=.git,target=.git \
# install development dependencies (for testing)
RUN python3 -m pip install -e tests/vllm_test_utils
# install transformers-neuronx package as an optional dependencies (for V0)
# FIXME: `--no-deps` argument is temporarily added to resolve transformers package version conflict
RUN python3 -m pip install transformers-neuronx==0.13.* --extra-index-url=https://pip.repos.neuron.amazonaws.com -U --no-deps
# overwrite entrypoint to run bash script
RUN echo "import subprocess; import sys; subprocess.check_call(sys.argv[1:])" > /usr/local/bin/dockerd-entrypoint.py
...
...
requirements-neuron.txt
View file @
c45d398e
...
...
@@ -2,6 +2,5 @@
-r requirements-common.txt
# Dependencies for Neuron devices
transformers-neuronx >= 0.13.0
torch-neuronx >= 2.5.0
neuronx-cc
setup.py
View file @
c45d398e
...
...
@@ -374,12 +374,7 @@ def _is_hip() -> bool:
def
_is_neuron
()
->
bool
:
torch_neuronx_installed
=
True
try
:
subprocess
.
run
([
"neuron-ls"
],
capture_output
=
True
,
check
=
True
)
except
(
FileNotFoundError
,
PermissionError
,
subprocess
.
CalledProcessError
):
torch_neuronx_installed
=
False
return
torch_neuronx_installed
or
VLLM_TARGET_DEVICE
==
"neuron"
return
VLLM_TARGET_DEVICE
==
"neuron"
def
_is_tpu
()
->
bool
:
...
...
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