Skip to content

Commit c96a246

Browse files
committed
remove ppo tests from ci
1 parent 2482043 commit c96a246

File tree

1 file changed

+189
-0
lines changed

1 file changed

+189
-0
lines changed
Lines changed: 189 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,189 @@
1+
# TODO: This workflow will not pass in CI yet. It needs:
2+
# - uploading dummy reward model to verl CI
3+
4+
# # Tests layout
5+
6+
# Each folder under tests/ corresponds to a test category for a sub-namespace in verl. For instance:
7+
# - `tests/trainer` for testing functionality related to `verl/trainer`
8+
# - `tests/models` for testing functionality related to `verl/models`
9+
# - ...
10+
11+
# There are a few folders with `special_` prefix, created for special purposes:
12+
# - `special_distributed`: unit tests that must run with multiple GPUs
13+
# - `special_e2e`: end-to-end tests with training/generation scripts
14+
# - `special_npu`: tests for NPUs
15+
# - `special_sanity`: a suite of quick sanity tests
16+
# - `special_standalone`: a set of test that are designed to run in dedicated environments
17+
18+
# Accelerators for tests
19+
# - By default tests are run with GPU available, except for the ones under `special_npu`, and any test script whose name ends with `on_cpu.py`.
20+
# - For test scripts with `on_cpu.py` name suffix would be tested on CPU resources in linux environment.
21+
22+
# # Workflow layout
23+
24+
# All CI tests are configured by yaml files in `.github/workflows/`. Here's an overview of all test configs:
25+
# 1. A list of always triggered CPU sanity tests: `check-pr-title.yml`, `secrets_scan.yml`, `check-pr-title,yml`, `pre-commit.yml`, `doc.yml`
26+
# 2. Some heavy multi-GPU unit tests, such as `model.yml`, `vllm.yml`, `sgl.yml`
27+
# 3. End-to-end tests: `e2e_*.yml`
28+
# 4. Unit tests
29+
# - `cpu_unit_tests.yml`, run pytest on all scripts with file name pattern `tests/**/test_*_on_cpu.py`
30+
# - `gpu_unit_tests.yml`, run pytest on all scripts with file without the `on_cpu.py` suffix.
31+
# - Since cpu/gpu unit tests by default runs all tests under `tests`, please make sure tests are manually excluded in them when
32+
# - new workflow yaml is added to `.github/workflows`
33+
# - new tests are added to workflow mentioned in 2.
34+
35+
name: e2e_grpo_trainer_trtllm
36+
37+
on:
38+
# Trigger the workflow on push or pull request,
39+
# but only for the main branch.
40+
# For push, for now only anti-patterns are specified so it is more conservative
41+
# and achieves higher coverage.
42+
push:
43+
branches:
44+
- main
45+
- v0.*
46+
paths:
47+
- "**/*.py"
48+
# Other entrypoints
49+
- "!verl/trainer/fsdp_sft_trainer.py"
50+
# Recipes
51+
- "!recipe/**"
52+
# FSDP
53+
- "!verl/workers/**/*dp_*.py"
54+
pull_request:
55+
branches:
56+
- main
57+
- v0.*
58+
paths:
59+
- "**/*.py"
60+
# Other entrypoints
61+
- "!docker/**"
62+
# Docs
63+
- "!**/*.md"
64+
- "!docs/**"
65+
- "!examples/**"
66+
- "!tests/**"
67+
- "!verl/trainer/main_*.py"
68+
- "!verl/trainer/fsdp_sft_trainer.py"
69+
# Recipes
70+
- "!recipe/**"
71+
# FSDP
72+
- "!verl/workers/**/*dp_*.py"
73+
# Entrypoints
74+
- "verl/workers/rollout/trtllm_rollout/*"
75+
- ".github/workflows/e2e_grpo_trainer_trtllm.yml"
76+
- "examples/data_preprocess/gsm8k.py"
77+
- "examples/data_preprocess/geo3k.py"
78+
79+
# Cancel jobs on the same ref if a new one is triggered
80+
concurrency:
81+
group: ${{ github.workflow }}-${{ github.ref }}
82+
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
83+
84+
# Declare permissions just read content.
85+
permissions:
86+
contents: read
87+
88+
env:
89+
IMAGE: "verl-ci-cn-beijing.cr.volces.com/verlai/verl:trtllm1.2.0rc6"
90+
DYNAMIC_RUNNER_ENDPOINT: "https://sd10g3clalm04ug7alq90.apigateway-cn-beijing.volceapi.com/runner"
91+
92+
jobs:
93+
setup:
94+
if: github.repository_owner == 'volcengine'
95+
runs-on: ubuntu-latest
96+
outputs:
97+
runner-label: ${{ steps.create-runner.outputs.runner-label }}
98+
mlp-task-id: ${{ steps.create-runner.outputs.mlp-task-id }}
99+
steps:
100+
- uses: actions/checkout@v4
101+
- id: create-runner
102+
uses: volcengine/vemlp-github-runner@v1
103+
with:
104+
mode: "create"
105+
faas-url: "${{ env.DYNAMIC_RUNNER_ENDPOINT }}"
106+
mlp-image: "${{ env.IMAGE }}"
107+
108+
e2e_grpo_trainer_fsdp-qwen2:
109+
needs: setup
110+
runs-on: ["${{ needs.setup.outputs.runner-label || 'L20x8' }}"]
111+
timeout-minutes: 30 # Increase this timeout value as needed
112+
env:
113+
HTTP_PROXY: ${{ secrets.PROXY_HTTP }}
114+
HTTPS_PROXY: ${{ secrets.PROXY_HTTPS }}
115+
NO_PROXY: "localhost,127.0.0.1,hf-mirror.com"
116+
HF_ENDPOINT: "https://hf-mirror.com"
117+
HF_HUB_ENABLE_HF_TRANSFER: "0" # This is more stable
118+
RAY_EXPERIMENTAL_NOSET_CUDA_VISIBLE_DEVICES: "1"
119+
steps:
120+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
121+
with:
122+
fetch-depth: 0
123+
- name: Install the current repository
124+
run: |
125+
pip3 install -r requirements-test.txt
126+
pip3 install --no-deps -e .
127+
- name: Prepare GSM8K and MATH datasets
128+
run: |
129+
python3 examples/data_preprocess/gsm8k.py --local_dataset_path ${HOME}/models/hf_data/gsm8k
130+
python3 examples/data_preprocess/math_dataset.py --local_dataset_path ${HOME}/models/hf_data/math
131+
- name: Running GSM8K E2E training tests with FSDP on 8 L20 GPUs (Qwen)
132+
run: |
133+
ray stop --force
134+
DATADIR=${HOME}/data \
135+
bash examples/grpo_trainer/run_qwen2-7b_math_trtllm.sh 4 \
136+
trainer.total_training_steps=2
137+
- name: clean up
138+
run: |
139+
rm -rf checkpoints
140+
141+
e2e_grpo_trainer_megatron-qwen2:
142+
needs: setup
143+
runs-on: ["${{ needs.setup.outputs.runner-label || 'L20x8' }}"]
144+
timeout-minutes: 30 # Increase this timeout value as needed
145+
env:
146+
HTTP_PROXY: ${{ secrets.PROXY_HTTP }}
147+
HTTPS_PROXY: ${{ secrets.PROXY_HTTPS }}
148+
NO_PROXY: "localhost,127.0.0.1,hf-mirror.com"
149+
HF_ENDPOINT: "https://hf-mirror.com"
150+
HF_HUB_ENABLE_HF_TRANSFER: "0" # This is more stable
151+
RAY_EXPERIMENTAL_NOSET_CUDA_VISIBLE_DEVICES: "1"
152+
steps:
153+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
154+
with:
155+
fetch-depth: 0
156+
- name: Install the current repository
157+
run: |
158+
pip3 install -r requirements-test.txt
159+
pip3 install --no-deps -e .
160+
- name: Prepare GSM8K and MATH datasets
161+
run: |
162+
python3 examples/data_preprocess/gsm8k.py --local_dataset_path ${HOME}/models/hf_data/gsm8k
163+
python3 examples/data_preprocess/math_dataset.py --local_dataset_path ${HOME}/models/hf_data/math
164+
- name: Running GSM8K E2E training tests with 3D parallelism on 8 L20 GPUs with Megatron (Qwen)
165+
run: |
166+
ray stop --force
167+
DATADIR=${HOME}/data \
168+
bash examples/grpo_trainer/run_qwen2-7b_math_megatron_trtllm.sh 1 \
169+
trainer.total_training_steps=2
170+
- name: clean up
171+
run: |
172+
rm -rf checkpoints
173+
174+
cleanup:
175+
runs-on: ubuntu-latest
176+
needs:
177+
[
178+
setup,
179+
e2e_grpo_trainer_fsdp-qwen2,
180+
e2e_grpo_trainer_megatron-qwen2
181+
]
182+
if: always()
183+
steps:
184+
- id: destroy-runner
185+
uses: volcengine/vemlp-github-runner@v1
186+
with:
187+
mode: "destroy"
188+
faas-url: "${{ env.DYNAMIC_RUNNER_ENDPOINT }}"
189+
mlp-task-id: "${{ needs.setup.outputs.mlp-task-id }}"

0 commit comments

Comments
 (0)