1313# limitations under the License.
1414
1515# setup.py is the fallback installation script when pyproject.toml does not work
16- from setuptools import setup , find_packages
1716import os
17+ from pathlib import Path
18+
19+ from setuptools import find_packages , setup
1820
1921version_folder = os .path .dirname (os .path .join (os .path .abspath (__file__ )))
2022
21- with open (os .path .join (version_folder , ' verl/version/version' )) as f :
23+ with open (os .path .join (version_folder , " verl/version/version" )) as f :
2224 __version__ = f .read ().strip ()
2325
26+ install_requires = [
27+ "accelerate" ,
28+ "codetiming" ,
29+ "datasets" ,
30+ "dill" ,
31+ "hydra-core" ,
32+ "numpy" ,
33+ "pandas" ,
34+ "peft" ,
35+ "pyarrow>=19.0.0" ,
36+ "pybind11" ,
37+ "pylatexenc" ,
38+ "ray[default]>=2.41.0" ,
39+ "torchdata" ,
40+ "tensordict<=0.6.2" ,
41+ "transformers<=4.51.1" ,
42+ "wandb" ,
43+ "packaging>=20.0" ,
44+ "qwen-vl-utils[decord]" ,
45+ ]
2446
25- with open ('requirements.txt' ) as f :
26- required = f .read ().splitlines ()
27- install_requires = [item .strip () for item in required if item .strip ()[0 ] != '#' ]
47+ TEST_REQUIRES = ["pytest" , "pre-commit" , "py-spy" ]
48+ PRIME_REQUIRES = ["pyext" ]
49+ GEO_REQUIRES = ["mathruler" ]
50+ GPU_REQUIRES = ["liger-kernel" , "flash-attn" ]
51+ MATH_REQUIRES = ["math-verify" ] # Add math-verify as an optional dependency
52+ VLLM_REQUIRES = ["tensordict<=0.6.2" , "vllm<=0.8.5" ]
53+ SGLANG_REQUIRES = [
54+ "tensordict<=0.6.2" ,
55+ "sglang[srt,openai]==0.4.6.post5" ,
56+ "torch-memory-saver>=0.0.5" ,
57+ "torch==2.6.0" ,
58+ ]
2859
2960extras_require = {
30- 'test' : ['pytest' , 'yapf' ]
61+ "test" : TEST_REQUIRES ,
62+ "prime" : PRIME_REQUIRES ,
63+ "geo" : GEO_REQUIRES ,
64+ "gpu" : GPU_REQUIRES ,
65+ "math" : MATH_REQUIRES ,
66+ "vllm" : VLLM_REQUIRES ,
67+ "sglang" : SGLANG_REQUIRES ,
3168}
3269
33- from pathlib import Path
70+
3471this_directory = Path (__file__ ).parent
3572long_description = (this_directory / "README.md" ).read_text ()
3673
3774setup (
38- name = ' verl' ,
75+ name = " verl" ,
3976 version = __version__ ,
40- package_dir = {'' : '.' },
41- packages = find_packages (where = '.' ),
42- url = ' https://github.com/volcengine/verl' ,
43- license = ' Apache 2.0' ,
44- author = ' Bytedance - Seed - MLSys' ,
45- author_email = ' zhangchi.usc1992@bytedance.com, gmsheng@connect.hku.hk' ,
46- description = 'veRL : Volcano Engine Reinforcement Learning for LLM' ,
77+ package_dir = {"" : "." },
78+ packages = find_packages (where = "." ),
79+ url = " https://github.com/volcengine/verl" ,
80+ license = " Apache 2.0" ,
81+ author = " Bytedance - Seed - MLSys" ,
82+ author_email = " zhangchi.usc1992@bytedance.com, gmsheng@connect.hku.hk" ,
83+ description = "verl : Volcano Engine Reinforcement Learning for LLM" ,
4784 install_requires = install_requires ,
4885 extras_require = extras_require ,
49- package_data = {'' : ['version/*' ],
50- 'verl' : ['trainer/config/*.yaml' ],},
86+ package_data = {
87+ "" : ["version/*" ],
88+ "verl" : ["trainer/config/*.yaml" ],
89+ },
5190 include_package_data = True ,
5291 long_description = long_description ,
53- long_description_content_type = ' text/markdown'
92+ long_description_content_type = " text/markdown" ,
5493)
0 commit comments