Commit 61e4397
authored
[misc] refactor: deprecate sharding manager (part 1) (volcengine#2912)
### What does this PR do?
- Since we introduce register device_mesh inside the worker, there is no
need to use sharding manager any longer. We will remove the usage of
sharding manager gradually in the main branch.
- This PR removes the sharding manager usage inside fsdp_workers
### Checklist Before Starting
- [ ] Search for similar PRs. Paste at least one query link here: ...
- [ ] Format the PR title as `[{modules}] {type}: {description}` (This
will be checked by the CI)
- `{modules}` include `fsdp`, `megatron`, `sglang`, `vllm`, `rollout`,
`trainer`, `ci`, `training_utils`, `recipe`, `hardware`, `deployment`,
`ray`, `worker`, `single_controller`, `misc`, `perf`, `model`, `algo`,
`env`, `tool`, `ckpt`, `doc`, `data`
- If this PR involves multiple modules, separate them with `,` like
`[megatron, fsdp, doc]`
- `{type}` is in `feat`, `fix`, `refactor`, `chore`, `test`
- If this PR breaks any API (CLI arguments, config, function signature,
etc.), add `[BREAKING]` to the beginning of the title.
- Example: `[BREAKING][fsdp, megatron] feat: dynamic batching`
### Test
> For changes that can not be tested by CI (e.g., algorithm
implementation, new model support), validate by experiment(s) and show
results like training curve plots, evaluation results, etc.
### API and Usage Example
> Demonstrate how the API changes if any, and provide usage example(s)
if possible.
```python
# Add code snippet or script demonstrating how to use this
```
### Design & Code Changes
> Demonstrate the high-level design if this PR is complex, and list the
specific changes.
### Checklist Before Submitting
> [!IMPORTANT]
> Please check all the following items before requesting a review,
otherwise the reviewer might deprioritize this PR for review.
- [ ] Read the [Contribute
Guide](https://github.com/volcengine/verl/blob/main/CONTRIBUTING.md).
- [ ] Apply [pre-commit
checks](https://github.com/volcengine/verl/blob/main/CONTRIBUTING.md#code-linting-and-formatting):
`pre-commit install && pre-commit run --all-files --show-diff-on-failure
--color=always`
- [ ] Add / Update [the
documentation](https://github.com/volcengine/verl/tree/main/docs).
- [ ] Add unit or end-to-end test(s) to [the CI
workflow](https://github.com/volcengine/verl/tree/main/.github/workflows)
to cover all the code. If not feasible, explain why: ...
- [ ] Once your PR is ready for CI, send a message in [the `ci-request`
channel](https://verl-project.slack.com/archives/C091TCESWB1) in [the
`verl` Slack
workspace](https://join.slack.com/t/verl-project/shared_invite/zt-3855yhg8g-CTkqXu~hKojPCmo7k_yXTQ).
(If not accessible, please try [the Feishu group
(飞书群)](https://applink.larkoffice.com/client/chat/chatter/add_by_link?link_token=772jd4f1-cd91-441e-a820-498c6614126a).)1 parent 7e3bd6a commit 61e4397
File tree
7 files changed
+126
-84
lines changed- recipe
- one_step_off_policy
- spin
- verl
- single_controller/base
- workers
- actor
- critic
7 files changed
+126
-84
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
| 27 | + | |
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
| |||
184 | 184 | | |
185 | 185 | | |
186 | 186 | | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
187 | 193 | | |
188 | 194 | | |
189 | 195 | | |
| |||
214 | 220 | | |
215 | 221 | | |
216 | 222 | | |
217 | | - | |
| 223 | + | |
218 | 224 | | |
219 | 225 | | |
220 | 226 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
32 | | - | |
| 32 | + | |
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| |||
167 | 167 | | |
168 | 168 | | |
169 | 169 | | |
170 | | - | |
| 170 | + | |
171 | 171 | | |
172 | 172 | | |
173 | 173 | | |
| |||
180 | 180 | | |
181 | 181 | | |
182 | 182 | | |
183 | | - | |
184 | 183 | | |
185 | 184 | | |
186 | | - | |
187 | 185 | | |
188 | 186 | | |
189 | 187 | | |
| |||
194 | 192 | | |
195 | 193 | | |
196 | 194 | | |
197 | | - | |
| 195 | + | |
198 | 196 | | |
199 | 197 | | |
200 | 198 | | |
| |||
209 | 207 | | |
210 | 208 | | |
211 | 209 | | |
212 | | - | |
213 | 210 | | |
214 | 211 | | |
215 | 212 | | |
216 | 213 | | |
217 | | - | |
218 | 214 | | |
219 | 215 | | |
220 | 216 | | |
| |||
229 | 225 | | |
230 | 226 | | |
231 | 227 | | |
232 | | - | |
| 228 | + | |
233 | 229 | | |
234 | 230 | | |
235 | 231 | | |
| |||
253 | 249 | | |
254 | 250 | | |
255 | 251 | | |
256 | | - | |
257 | | - | |
258 | 252 | | |
259 | 253 | | |
260 | 254 | | |
| |||
282 | 276 | | |
283 | 277 | | |
284 | 278 | | |
285 | | - | |
286 | 279 | | |
287 | 280 | | |
288 | 281 | | |
| |||
323 | 316 | | |
324 | 317 | | |
325 | 318 | | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
326 | 327 | | |
327 | 328 | | |
328 | 329 | | |
| |||
539 | 540 | | |
540 | 541 | | |
541 | 542 | | |
542 | | - | |
| 543 | + | |
543 | 544 | | |
544 | 545 | | |
545 | 546 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
70 | 70 | | |
71 | 71 | | |
72 | 72 | | |
73 | | - | |
74 | | - | |
75 | 73 | | |
76 | 74 | | |
77 | 75 | | |
| |||
102 | 100 | | |
103 | 101 | | |
104 | 102 | | |
| 103 | + | |
| 104 | + | |
105 | 105 | | |
106 | 106 | | |
107 | 107 | | |
| |||
117 | 117 | | |
118 | 118 | | |
119 | 119 | | |
120 | | - | |
| 120 | + | |
121 | 121 | | |
122 | 122 | | |
123 | 123 | | |
| |||
133 | 133 | | |
134 | 134 | | |
135 | 135 | | |
136 | | - | |
| 136 | + | |
137 | 137 | | |
138 | 138 | | |
139 | 139 | | |
| |||
219 | 219 | | |
220 | 220 | | |
221 | 221 | | |
| 222 | + | |
| 223 | + | |
222 | 224 | | |
223 | 225 | | |
224 | 226 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
410 | 410 | | |
411 | 411 | | |
412 | 412 | | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
413 | 418 | | |
414 | 419 | | |
415 | 420 | | |
| |||
449 | 454 | | |
450 | 455 | | |
451 | 456 | | |
452 | | - | |
| 457 | + | |
453 | 458 | | |
454 | 459 | | |
455 | 460 | | |
456 | 461 | | |
457 | | - | |
| 462 | + | |
458 | 463 | | |
459 | | - | |
| 464 | + | |
460 | 465 | | |
461 | 466 | | |
462 | 467 | | |
463 | 468 | | |
464 | | - | |
| 469 | + | |
465 | 470 | | |
466 | 471 | | |
467 | 472 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
238 | 238 | | |
239 | 239 | | |
240 | 240 | | |
241 | | - | |
| 241 | + | |
| 242 | + | |
242 | 243 | | |
243 | | - | |
| 244 | + | |
| 245 | + | |
244 | 246 | | |
245 | 247 | | |
246 | 248 | | |
247 | 249 | | |
248 | 250 | | |
249 | | - | |
| 251 | + | |
250 | 252 | | |
251 | 253 | | |
252 | 254 | | |
| |||
0 commit comments