-
Notifications
You must be signed in to change notification settings - Fork 88
[Dependencies] Upgrade to torch 2.7 #73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 1 commit
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
e0d12fc
upgrade
SumanthRH 4c2532e
x
SumanthRH 327592d
update examples, remove old patch
SumanthRH 2bdf387
x
SumanthRH 8f538d7
edits
SumanthRH 276e01f
standardize on str for update weight
SumanthRH 4df8a73
x
SumanthRH 5d4a0cf
x
SumanthRH d0897eb
x
SumanthRH d8dae04
x
SumanthRH 40d389f
x
SumanthRH 82f48d1
x
SumanthRH 917aa58
x
SumanthRH 8027c87
x
SumanthRH b6531dd
x
SumanthRH 9e76064
x
SumanthRH a633159
search r1
SumanthRH d5f5c96
x
SumanthRH d3b21d5
merge from main
SumanthRH File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,24 @@ | ||
FROM anyscale/ray:2.44.0-slim-py312-cu124 | ||
FROM anyscale/ray:2.44.0-slim-py312-cu128 | ||
|
||
RUN sudo apt-get update -y && sudo apt-get install -y wget kmod libxml2 build-essential libnuma-dev | ||
|
||
# the cuda compiler here is needed for deepspeed | ||
RUN wget https://developer.download.nvidia.com/compute/cuda/12.4.0/local_installers/cuda_12.4.0_550.54.14_linux.run | ||
RUN sudo sh cuda_12.4.0_550.54.14_linux.run --silent --toolkit | ||
RUN wget https://developer.download.nvidia.com/compute/cuda/12.8.0/local_installers/cuda_12.8.0_570.86.10_linux.run \ | ||
&& sudo sh cuda_12.8.0_570.86.10_linux.run --silent --toolkit && rm -rf cuda_12.8.0_570.86.10_linux.run | ||
|
||
RUN curl -LsSf https://astral.sh/uv/install.sh | sh | ||
RUN echo "export RAY_RUNTIME_ENV_HOOK=ray._private.runtime_env.uv_runtime_env_hook.hook" >> /home/ray/.bashrc | ||
|
||
RUN sudo apt-get update \ | ||
&& sudo apt-get install -y openssh-server iputils-ping net-tools iproute2 traceroute netcat \ | ||
libopenexr-dev libxi-dev libglfw3-dev libglew-dev libomp-dev libxinerama-dev libxcursor-dev tzdata | ||
RUN sudo apt update && sudo apt install --fix-broken && sudo apt install -y default-jre-headless openjdk-8-jdk | ||
libopenexr-dev libxi-dev libglfw3-dev libglew-dev libomp-dev libxinerama-dev libxcursor-dev tzdata \ | ||
&& sudo apt-get clean && sudo rm -rf /var/lib/apt/lists/* | ||
|
||
RUN sudo apt update && sudo apt install --fix-broken && sudo apt install -y default-jre-headless openjdk-8-jdk \ | ||
&& sudo apt-get clean \ | ||
&& sudo rm -rf /var/lib/apt/lists/* | ||
|
||
# NOTE: vllm installation in base environment is needed for uv + vLLM to work | ||
RUN pip install vllm==0.8.5 | ||
RUN pip install ray==2.44.0 | ||
RUN pip install vllm==0.9.2 \ | ||
&& pip install ray==2.44.0 \ | ||
&& rm -rf ~/.cache/pip |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,7 +19,7 @@ classifiers = [ | |
] | ||
|
||
dependencies = [ | ||
"flash-attn@https://github.com/Dao-AILab/flash-attention/releases/download/v2.7.4.post1/flash_attn-2.7.4.post1+cu12torch2.6cxx11abiFALSE-cp312-cp312-linux_x86_64.whl", | ||
"flash-attn@https://github.com/Dao-AILab/flash-attention/releases/download/v2.8.0.post2/flash_attn-2.8.0.post2+cu12torch2.7cxx11abiFALSE-cp312-cp312-linux_x86_64.whl", | ||
"loguru", | ||
"tqdm", | ||
"tensorboard", | ||
|
@@ -51,6 +51,7 @@ conflicts = [ | |
|
||
[tool.uv.sources] | ||
skyrl-gym = { path = "./skyrl-gym" , editable = true } | ||
torch = { index = "pytorch-cu128" } | ||
|
||
[project.optional-dependencies] | ||
deepspeed = [ | ||
|
@@ -72,20 +73,26 @@ docs = [ | |
"sphinx-autobuild>=2021.3.14" | ||
] | ||
vllm = [ | ||
"vllm==0.8.5", | ||
"vllm==0.9.2", | ||
# NOTE (sumanthrh): We explictly use a flashinfer wheel from their index. | ||
# The wheels on PyPI don't come with pre-compiled kernels and the package will JIT compile them at runtime (terribly slow). | ||
"flashinfer-python@https://github.com/flashinfer-ai/flashinfer/releases/download/v0.2.5/flashinfer_python-0.2.5+cu124torch2.6-cp38-abi3-linux_x86_64.whl#sha256=43d767b912c0c43a04be99595e0123eab9385fc72530a2874b5fb08e3145c0be", | ||
"flashinfer-python@https://download.pytorch.org/whl/cu128/flashinfer/flashinfer_python-0.2.6.post1%2Bcu128torch2.7-cp39-abi3-linux_x86_64.whl", | ||
] | ||
sglang = [ | ||
"sglang[srt,openai]==0.4.6.post4", | ||
"sglang[srt,openai]==0.4.8.post1", | ||
"torch-memory-saver>=0.0.5", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think you can do There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks! |
||
# The version is pinned to 0.2.5 because sglang requires this | ||
# NOTE (sumanthrh): This can be made a common dependency, but then different inference engines can pin different compatible flashinfer versions and it might quickly break. | ||
"flashinfer-python@https://github.com/flashinfer-ai/flashinfer/releases/download/v0.2.5/flashinfer_python-0.2.5+cu124torch2.6-cp38-abi3-linux_x86_64.whl#sha256=43d767b912c0c43a04be99595e0123eab9385fc72530a2874b5fb08e3145c0be", | ||
"flashinfer-python@https://download.pytorch.org/whl/cu128/flashinfer/flashinfer_python-0.2.6.post1%2Bcu128torch2.7-cp39-abi3-linux_x86_64.whl", | ||
"torch==2.7.1", | ||
] | ||
|
||
|
||
[[tool.uv.index]] | ||
name = "pytorch-cu128" | ||
url = "https://download.pytorch.org/whl/cu128" | ||
explicit = true | ||
|
||
[tool.setuptools.packages.find] | ||
include = ["skyrl_train*"] | ||
|
||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] Multiple
RUN apt-get update
and cleanup layers can be consolidated into a singleRUN
block to reduce image layers and overall size.Copilot uses AI. Check for mistakes.