Commit b4d6a40
torchrec related changes for APF Integration (#3648)
Summary:
X-link: pytorch/FBGEMM#5286
Pull Request resolved: #3648
X-link: https://github.com/facebookresearch/FBGEMM/pull/2279
**Overview**
This diff introduces key changes to enable APF compatibility and column-wise sharding for SSD Offloading in TorchRec. The updates focus on sharding logic, configuration, and integration with SSD-backed embedding tables.
**Key Changes**
1. Added support for column-wise sharding for SSD Offloading by creating a new sharding logic to device partitioning logic for column-wise sharding with SSD-backed tables, ensuring unique rank assignment and load balancing.
2. Configuration and Planner Updates
Functions such as get_sharding_planner, get_sharding_plan, and related helpers now accept and process sharding constraints, including those specific to SSD Offloading.
The sharding helpers can now handle key-value storage parameters, enabling SSD integration.
Reviewed By: TroyGarden
Differential Revision: D89049866
fbshipit-source-id: 25fb259c442c376ae6b07dd07222a20c2bece8301 parent 29a42da commit b4d6a40
File tree
2 files changed
+91
-6
lines changed- torchrec/distributed
- planner
2 files changed
+91
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2983 | 2983 | | |
2984 | 2984 | | |
2985 | 2985 | | |
2986 | | - | |
2987 | | - | |
2988 | | - | |
2989 | 2986 | | |
2990 | 2987 | | |
2991 | 2988 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
309 | 309 | | |
310 | 310 | | |
311 | 311 | | |
312 | | - | |
313 | | - | |
314 | | - | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
315 | 321 | | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
316 | 329 | | |
317 | 330 | | |
318 | 331 | | |
| |||
329 | 342 | | |
330 | 343 | | |
331 | 344 | | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
332 | 420 | | |
333 | 421 | | |
334 | 422 | | |
| |||
0 commit comments