-
Notifications
You must be signed in to change notification settings - Fork 591
[MLPerf 6.1][DLRMv4] Adding DLRMv4 HSTU #889
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
carualejandro
merged 159 commits into
mlcommons:master
from
chriscai-amd:chcai/dlrmv4-idfix
Aug 12, 2026
Merged
Changes from all commits
Commits
Show all changes
159 commits
Select commit
Hold shift + click to select a range
461b0f4
Add recommendation_v4 (HSTU/DLRM-v3 generative-recommenders fork @ d9…
chriscai-amd 9b56d4f
Enable Triton HSTU kernels on AMD/ROCm (gfx950 MI350X)
chriscai-amd 751f2f0
Fix AttributeError on triton.knobs.nvidia.use_meta_ws
chriscai-amd 0f1fcf0
Make HSTU model arch + dataset history_length gin-tunable
chriscai-amd b7f8b2d
Make EmbeddingShardingPlanner hbm_cap_gb gin-tunable, set ddr_cap=0
chriscai-amd 5ba9b07
Add yambda 50m/500m/5b preprocessor + DLRM_DATA_PATH env override
chriscai-amd c639f6a
Fix NCCL init: set CUDA device before init_process_group
chriscai-amd d76f96b
Profiler: write traces to local disk under <repo>/results/<run_name>/
chriscai-amd 4a2a7bd
Tracing fixes: gin scoping, drop active=10 override, intuitive filena…
chriscai-amd 9b0ae8b
gin: history_length 2048 → 2039 + expanded per-pool comment
chriscai-amd 2b58a63
README: rewrite for yambda-5b fork — upstream link, data prep, per-po…
chriscai-amd 03662de
gin: make hbm_cap_gb overridable via \$HBM_CAP_GB
chriscai-amd bb012a2
docs: add B200 training recipe for yambda-5b
chriscai-amd 8d8844b
bf16 + triton autotune pinning with gin-driven full-tune override
chriscai-amd 1c9315a
docs: add MI350X training recipe section
chriscai-amd 3027519
scripts: add stitch_traces.py
chriscai-amd 8cbbab0
docs: update B200 recipe deps to NGC 26.04 (torch 2.12 / CUDA 13.2)
chriscai-amd fc4d092
docs: refresh B200 recipe deps (fbgemm HEAD, torchrec 1.7 nightly, dr…
chriscai-amd 194fc9b
MI350X: re-pin 2 triton configs for the torch 2.12 + torchrec 1.7 stack
chriscai-amd 671e7e6
docs: update MI350X Stack B to fbgemm @ B200 commit + caveat
chriscai-amd b3d1764
docs: drop Stack A; MI350X recipe is now single-stack (B200-aligned)
chriscai-amd 7f6553e
docs: drop PYTORCH-fallback caveat from MI350X recipe
chriscai-amd cb68c8e
MI350X: fit-entity embedding sizes, bs=1024 default, batch-agnostic r…
chriscai-amd 2e95a4d
MI350X: separated-RNG LN-dropout + attention autotune pin + clock guard
chriscai-amd 17e04af
dlrmv4: TorchRec 3-stage sparse-dist pipeline + gin-selectable HSTU k…
chriscai-amd 123c55c
dlrmv4: streaming (temporal-order) training for yambda-5b
chriscai-amd d017bcc
dlrmv4: disable checkpointing by default; fix recipe torch note
chriscai-amd 7d11c17
dlrmv4: ROCm-only Perfetto trace render fixes at export time
chriscai-amd e024217
dlrmv4: ROCm annotation de-overlap so phase spans render full width
chriscai-amd f447075
dlrmv4: streaming checkpoint resume + step/time checkpoint cadences
chriscai-amd 4a18b95
dlrmv4: move streaming resume test harness into train/tests
chriscai-amd f89da0e
dlrmv4: sparse full-holdout eval cadence + eval-pool fork-race fix
chriscai-amd 039f7c9
dlrmv4: self-healing streaming-e2e supervisor + NE/AUC trajectory bui…
chriscai-amd 0be8a71
dlrmv4: durable streaming-run metrics (append log + TensorBoard on NFS)
chriscai-amd da8a9eb
dlrmv4: raise streaming-run disk guard for keep_last_n=1 saves
chriscai-amd 3c896c9
dlrmv4: anchor eval points to train global step in NE/AUC trajectory
chriscai-amd 04dc53a
dlrmv4: supervisor tolerates control-plane outages + attach mode
chriscai-amd 45e0daf
dlrmv4: TFLOPS/MFU/HFU reporting + MAX_SEQ_LEN/HISTORY_LENGTH gin knobs
chriscai-amd e794c0a
dlrmv4: configurable lifetime-AUC backend + fixed-holdout streaming eval
chriscai-amd efc5126
dlrmv4: default yambda-5b to the 4k-no-truncation seq shape
chriscai-amd 03362da
dlrmv4: reservation-aware sbatch failover in streaming supervisor
chriscai-amd 888f701
dlrmv4: two-tier reservation-then-open-pool failover in streaming sup…
chriscai-amd 7c36891
dlrmv4: cap failover at <=1 reservation node + fix trainer-alive self…
chriscai-amd 7c9188f
dlrmv4: anchor sparse-eval cadence to absolute window ts (resume-inva…
chriscai-amd dbb9e1d
dlrmv4: multi-node (N>=1) training over RoCE RDMA via consolidated la…
chriscai-amd 15c4a00
local dlrmv4 changes: docker setup, run scripts, walkthrough docs, sm…
suachong d03fb28
dlrmv4: decouple multi-node launch from per-user paths for portable b…
suachong c55736e
dlrmv4: deterministic in-window shuffle diversity dial + opt-in diagn…
chriscai-amd 851a354
dlrmv4: MLPerf training compliance logging for streaming-train-eval
suachong 2fc3cb1
dlrmv4: min_history anchor-eligibility floor (decoupled from history_…
chriscai-amd e5214b8
dlrmv4: gin defaults — min_history=1, BATCH_SIZE env knob, default to…
chriscai-amd 5fdf70c
dlrmv4: launch_slurm container hygiene + readiness gating + env passt…
chriscai-amd 6182ab4
dlrmv4: durable per-boundary eval metrics JSONL sink + aggregate emb-…
chriscai-amd 51e6e5f
dlrmv4: default MIN_HISTORY=0 (include cold-start first events) to ma…
chriscai-amd 03a5be1
dlrmv4: default NUM_TRAIN_TS=149 to sweep full ts=150..298 streaming …
chriscai-amd 20f6917
dlrmv4: consolidate eval cadence into single EVAL_EVERY_N_WINDOWS knob
chriscai-amd 9171e4f
dlrmv4: random per-run seed + graceful teardown + no double-logging
suachong 29ebfe2
Merge remote-tracking branch 'origin/chcai/dlrmv4' into suachong/dlrmv4
suachong ded9c30
dlrmv4: fix single-node-without-slurm via run_docker.sh
suachong 380b1ca
dlrmv4: gin-configurable quantized (bf16/fp16) embedding all-to-all
chriscai-amd 3e776a8
dlrmv4: split quantized a2a into independent fwd/bwd precision knobs
chriscai-amd 5f76993
dlrmv4: enable GPUDirect RDMA by default in slurm worker
suachong a34facc
dlrmv4: gin-configurable RNG seed ($SEED) + default TRAIN_SPLIT_PERCE…
chriscai-amd 40c696a
dlrmv4: env-configurable dense/sparse LR + optimizer LR logging
chriscai-amd d646b2a
dlrmv4: env-configurable HSTU transformer depth ($HSTU_NUM_LAYERS)
chriscai-amd 922aeec
dlrmv4: env-overridable dense/sparse LRs for sweeps + holdout default…
suachong 8a9282d
Merge remote-tracking branch 'origin/chcai/dlrmv4' into suachong/dlrmv4
suachong e0d6e46
dlrmv4: disable TensorBoard by default (no-op writer)
chriscai-amd bc743b5
dlrmv4: default dense/sparse LR=1e-5 and HSTU depth=3
chriscai-amd b4ce3ba
dlrmv4: report EVAL_ACCURACY as per-window AUC (configurable, default…
suachong c5469a4
dlrmv4: consolidate streaming e2e supervisor to one sbatch-wrapping s…
chriscai-amd be892d8
dlrmv4: add non-SLURM local launcher + self-healing supervisor
chriscai-amd 7f73ac7
dlrmv4: set default-PG timeout to TIMEOUT (1800s) to survive checkpoi…
chriscai-amd 66b18eb
Merge remote-tracking branch 'origin/chcai/dlrmv4' into suachong/dlrmv4
suachong 09b4204
dlrmv4: optional gradient clipping for the streaming path ($GRAD_CLIP…
chriscai-amd 3cb9eb6
dlrmv4: data-fraction eval cadence + lr1e-7/grad-clip-on defaults
chriscai-amd c2342c5
dlrmv4: seed embedding init + reproducibility checksum ($SEED)
chriscai-amd eef3304
dlrmv4: default INIT_CHECKSUM off (fp64 shard copy OOMs the build)
chriscai-amd 38a9175
dlrmv4: add last_n UIH history strategy ($HISTORY_STRATEGY)
chriscai-amd fde24f3
Merge remote-tracking branch 'origin/chcai/dlrmv4' into suachong/dlrmv4
suachong f14485a
dlrmv4: logging-freeze prep — MIN_HISTORY=4086 default + HISTORY_STRA…
suachong 53f5176
dlrmv4: untrack docs/v4_vs_v2_and_hstu_walkthrough.md
suachong 0f7a6eb
dlrmv4: scrub hardcoded username from reference comments
suachong 31a38fa
dlrmv4: README — add full single/multi-node reference run example
suachong 3cd9f6d
dlrmv4: exclude eval/checkpoint overhead from step_ms timing
chriscai-amd dc412ff
dlrmv4: README — use AUC_THRESHOLD=0.80275 in example for gin-default…
suachong fad177f
dlrmv4: make a bare sbatch reproduce the frozen reference run
suachong e078dd4
Merge remote-tracking branch 'origin/chcai/dlrmv4' into suachong/dlrmv4
suachong b50fe58
dlrmv4: address PR review — mlperf_logging install/pin + logging-util…
suachong 9d1dbf8
dlrmv4: decorrelate per-rank runtime RNG for HSTU dropout
suachong 784516a
dlrmv4: drop non-portable build/run helpers from the baseline
suachong 3f36f61
dlrmv4: trim PR comments, default DECORRELATE_DROPOUT off, extend eva…
suachong a9f8efd
dlrmv4: trim verbose MLPerf-wiring comments to 1-2 lines
suachong 024e64b
dlrmv4: trim seed_everything / decorrelate_runtime_rng docstrings
suachong f63e5d4
dlrmv4: drop .gitignore changes from the PR
suachong 02f2d2b
dlrmv4: centralize MLPerf emission + fix submission identity
suachong ae99293
dlrmv4: hardcode lifetime-AUC backend to binned, drop the override
suachong da74883
Revert "dlrmv4: hardcode lifetime-AUC backend to binned, drop the ove…
suachong 1ada43f
dlrmv4: slim launch_slurm.sh to MLPerf wiring + path portability
suachong 1d25713
dlrmv4: drop launch_slurm_suachong.sh from the PR (keep local only)
suachong 1dae61d
dlrmv4: revert streaming_resume_test.sh to base (out of MLPerf PR scope)
suachong 7ec6fcc
dlrmv4: make MLPerf run markers resume-aware via checkpoint state
chriscai-amd 5c2b940
dlrmv4: reproducible-by-default config (seed=1, AUC_THRESHOLD=1.0)
chriscai-amd ff55513
dlrmv4: re-enable GPUDirect RDMA by default in slurm worker
chriscai-amd 7b5e869
dlrmv4: README — match launcher's actual smoke-shaped defaults
chriscai-amd 392241f
Merge pull request #1 from chriscai-amd/suachong/dlrmv4
chriscai-amd 881d925
recommendation_v4: add MLPerf reference scripts, structure, and docs
chriscai-amd 4ca6c08
Merge pull request #2 from chriscai-amd/chcai/mlperf_refactor
chriscai-amd 4cf4d85
recommendation_v4: prune inference/AOT/CUDA-cpp/research + non-yambda…
chriscai-amd b68bfb7
Make data-fraction eval cadence the default
chriscai-amd 7e8de35
dlrmv3 streaming: fix distributed sync + generalize checkpoint/resume…
chriscai-amd f8807ca
dlrmv3 streaming: make resume e2e test pass on MI350/NFS
chriscai-amd ea37064
dlrmv3 streaming: document midwindow vs multiwindow resume test purpose
chriscai-amd e46358f
Merge pull request #3 from chriscai-amd/chcai/nv_fix
chriscai-amd 8db66f3
dlrmv3: gin/env-configurable embedding table placement (HBM/UVM)
chriscai-amd d0ce11e
dlrmv3 qcomm: hard-fail instead of silently falling back to fp32 a2a
chriscai-amd 584cb66
dlrmv3 yambda-5b: default embedding a2a quantization to fp16/fp16
chriscai-amd 3a69560
dlrmv3 yambda-5b: default gin to the canonical fp16 full-corpus run
chriscai-amd 4f987c1
dlrmv3 qcomm: low-memory fbgemm fp16/bf16 a2a codec to fix skewed-bat…
chriscai-amd a856229
dlrmv3 launch_slurm: forward QCOMM_LOWMEM_CODEC env into the container
chriscai-amd b8f8298
dlrmv3 sharding: gin/env-configurable per-table embedding sharding-ty…
chriscai-amd 8163b4e
dlrmv3 qcomm: gin/env-configurable EC in-batch index dedup (default on)
chriscai-amd 273475a
Add steps-to-target CV script for run-to-run convergence analysis.
suachong 795eccd
Move steps-to-target CV script under scripts/cv/.
suachong fe2a14d
Merge pull request #4 from chriscai-amd/suachong/cv-steps-to-target
chriscai-amd 2ef0465
dlrmv3 train: gin/env-configurable LR warmup (default OFF)
chriscai-amd 4baaa83
dlrmv3 train: configurable LR-warmup starting LR (default 0)
chriscai-amd a40f3fd
dlrmv3 train: gate interim eval metric logging (default OFF, AUC-neut…
chriscai-amd ac89f82
dlrmv4: add RCP reference logs by global batch size
suachong 5b1590d
dlrmv3 train: SKIP_EVAL to skip first N periodic eval passes (default 0)
chriscai-amd 23882d1
dlrmv4: expand RCP reference logs to 20 runs per global batch size
suachong 1a04549
Merge remote-tracking branch 'origin/chcai/dlrmv4-idfix' into suachon…
suachong 1c3c808
dlrmv4 gin: set CV-batch defaults (lr=1e-6, warmup=24k, eval=0.1%, sk…
suachong 28681cb
dlrmv4: drop rcp_logs/.gitignore negation
suachong 9505e0c
Merge pull request #5 from chriscai-amd/suachong/dlrmv4-rcp-logs
chriscai-amd de1be29
dlrmv4 README: document RCP convergence sweep + 0.75 eval target
817e379
dlrmv4 README: add epoch-to-converge and CV columns to RCP table
aaa39e8
dlrmv4 README: note skip_eval=10 as a fixed submission hyperparameter
8f723e7
dlrmv4: set RCP log submission_platform to MI350, drop rcp/ placeholder
bcede2a
dlrmv4: align documented + default eval cadence with the RCP sweep (0…
17ccef6
dlrmv4: replace count-based SKIP_EVAL with epoch-fraction SKIP_EVAL_E…
chriscai-amd 7d04457
dlrmv4 README: restructure onto the MLCommons benchmark README template
chriscai-amd 149df0d
dlrmv4 README: describe main hyperparameters without tunability framing
chriscai-amd 0413eaf
dlrmv4: add a 2-eval safety margin to the skip_eval_epoch_pct values
chriscai-amd 7f807f1
dlrmv4: fold the eval margin into the start-eval intercept
chriscai-amd 0f7c14b
dlrmv4: log the pinned hyperparameters and converge by default
chriscai-amd 4b4a2a5
dlrmv4: log the eval grid, grad clip norm and max sequence length
chriscai-amd 954b133
dlrmv4: rename the dlrm_v3 package and identifiers to dlrm_v4
chriscai-amd 0736ec6
dlrmv4: pin the real md5 checksums for the preprocessed yambda-5b data
chriscai-amd f551796
dlrmv4: verify the two shared_metadata item mappings as well
chriscai-amd 8cac749
dlrmv4: read item_popularity.npy from processed_dir and validate its …
chriscai-amd a30a01a
dlrmv4: document the prepared-dataset download and verify both layouts
chriscai-amd c57035a
dlrmv4: point the prepared-dataset download at the MLCommons hosted copy
chriscai-amd da2f5b8
dlrmv4: note that the md5 set is partial for a prepared download
chriscai-amd 52063e4
dlrmv4: document the model FLOPs accounting and name its multipliers
chriscai-amd a67b845
dlrmv4: describe the eval-start rule as a check on the first eval
chriscai-amd 3e573d1
Merge remote-tracking branch 'upstream/master' into chcai/dlrmv4-idfix
chriscai-amd 429deee
dlrmv4: unify the data-pct -> global-steps conversion; clarify fbgemm…
chriscai-amd a4f3e77
dlrmv4: rename the benchmark directory from recommendation_v4 to reco…
chriscai-amd 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 |
|---|---|---|
| @@ -0,0 +1,159 @@ | ||
| # Don't check in parsed data files and other temporary files | ||
| tmp/ | ||
| exps/ | ||
| ckpts/ | ||
| results/ | ||
|
|
||
| # Byte-compiled / optimized / DLL files | ||
| __pycache__/ | ||
| *.py[cod] | ||
| *$py.class | ||
|
|
||
| # C extensions | ||
| *.so | ||
|
|
||
| # Distribution / packaging | ||
| .Python | ||
| build/ | ||
| develop-eggs/ | ||
| dist/ | ||
| downloads/ | ||
| eggs/ | ||
| .eggs/ | ||
| lib/ | ||
| lib64/ | ||
| parts/ | ||
| sdist/ | ||
| var/ | ||
| wheels/ | ||
| share/python-wheels/ | ||
| *.egg-info/ | ||
| .installed.cfg | ||
| *.egg | ||
| MANIFEST | ||
|
|
||
| # PyInstaller | ||
| # Usually these files are written by a python script from a template | ||
| # before PyInstaller builds the exe, so as to inject date/other infos into it. | ||
| *.manifest | ||
| *.spec | ||
|
|
||
| # Installer logs | ||
| pip-log.txt | ||
| pip-delete-this-directory.txt | ||
|
|
||
| # Unit test / coverage reports | ||
| htmlcov/ | ||
| .tox/ | ||
| .nox/ | ||
| .coverage | ||
| .coverage.* | ||
| .cache | ||
| nosetests.xml | ||
| coverage.xml | ||
| *.cover | ||
| *.py,cover | ||
| .hypothesis/ | ||
| .pytest_cache/ | ||
| cover/ | ||
|
|
||
| # Translations | ||
| *.mo | ||
| *.pot | ||
|
|
||
| # Django stuff: | ||
| *.log | ||
| local_settings.py | ||
| db.sqlite3 | ||
| db.sqlite3-journal | ||
|
|
||
| # Flask stuff: | ||
| instance/ | ||
| .webassets-cache | ||
|
|
||
| # Scrapy stuff: | ||
| .scrapy | ||
|
|
||
| # Sphinx documentation | ||
| docs/_build/ | ||
|
|
||
| # PyBuilder | ||
| .pybuilder/ | ||
| target/ | ||
|
|
||
| # Jupyter Notebook | ||
| .ipynb_checkpoints | ||
|
|
||
| # IPython | ||
| profile_default/ | ||
| ipython_config.py | ||
|
|
||
| # pyenv | ||
| # For a library or package, you might want to ignore these files since the code is | ||
| # intended to run in multiple environments; otherwise, check them in: | ||
| # .python-version | ||
|
|
||
| # pipenv | ||
| # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. | ||
| # However, in case of collaboration, if having platform-specific dependencies or dependencies | ||
| # having no cross-platform support, pipenv may install dependencies that don't work, or not | ||
| # install all needed dependencies. | ||
| #Pipfile.lock | ||
|
|
||
| # poetry | ||
| # Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control. | ||
| # This is especially recommended for binary packages to ensure reproducibility, and is more | ||
| # commonly ignored for libraries. | ||
| # https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control | ||
| #poetry.lock | ||
|
|
||
| # pdm | ||
| # Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control. | ||
| #pdm.lock | ||
| # pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it | ||
| # in version control. | ||
| # https://pdm.fming.dev/#use-with-ide | ||
| .pdm.toml | ||
|
|
||
| # PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm | ||
| __pypackages__/ | ||
|
|
||
| # Celery stuff | ||
| celerybeat-schedule | ||
| celerybeat.pid | ||
|
|
||
| # SageMath parsed files | ||
| *.sage.py | ||
|
|
||
| # Environments | ||
| .env | ||
| .venv | ||
| env/ | ||
| venv/ | ||
| ENV/ | ||
| env.bak/ | ||
| venv.bak/ | ||
|
|
||
| # Spyder project settings | ||
| .spyderproject | ||
| .spyproject | ||
|
|
||
| # Rope project settings | ||
| .ropeproject | ||
|
|
||
| # mkdocs documentation | ||
| /site | ||
|
|
||
| # mypy | ||
| .mypy_cache/ | ||
| .dmypy.json | ||
| dmypy.json | ||
|
|
||
| # Pyre type checker | ||
| .pyre/ | ||
|
|
||
| # pytype static type analyzer | ||
| .pytype/ | ||
|
|
||
| # Cython debug symbols | ||
| cython_debug/ |
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 |
|---|---|---|
| @@ -0,0 +1,94 @@ | ||
| # MI350X path — implements docs/training_recipe.md §"MI350X". | ||
|
|
||
| FROM rocm/primus:v26.3 | ||
|
|
||
| ENV PYTHONUNBUFFERED=1 \ | ||
| PIP_NO_CACHE_DIR=1 \ | ||
| PIP_DISABLE_PIP_VERSION_CHECK=1 | ||
|
|
||
| WORKDIR /workspace/recommendation | ||
|
|
||
| # torch / torchvision / torchaudio — training_recipe.md:38-40. | ||
| RUN pip install --upgrade --no-deps \ | ||
| --index-url https://download.pytorch.org/whl/rocm7.2 \ | ||
| torch==2.12.0+rocm7.2 \ | ||
| torchvision==0.27.0+rocm7.2 \ | ||
| torchaudio==2.11.0+rocm7.2 | ||
|
|
||
| # torchrec — training_recipe.md:43. | ||
| RUN pip install --force-reinstall --no-deps \ | ||
| "git+https://github.com/pytorch/torchrec.git@v2026.06.01.00" | ||
|
|
||
| # fbgemm_gpu — training_recipe.md:42. requirements.txt pins `fbgemm_gpu==1.7.0`, | ||
| # but there is NO prebuilt gfx950 / ROCm 7.2 wheel for it: the public wheels on | ||
| # PyPI / download.pytorch.org are CUDA/CPU-only and ABI-incompatible with the | ||
| # torch 2.12.0+rocm7.2 installed above. So we compile that same 1.7.0 line from | ||
| # source at the pinned FBGEMM commit 10b77573 (same SHA as the B200 path), built | ||
| # against the replaced torch. setup.py's from-source artifact is named | ||
| # `fbgemm_gpu_nightly_rocm-<build-date>` (e.g. 2026.x) — the "nightly" is the | ||
| # package-CHANNEL name for a source build and the date is the BUILD date, not a | ||
| # nightly-vs-release version choice; identify this build by the commit, not the | ||
| # wheel's version string. ~30-60 min. | ||
| RUN apt-get update && apt-get install -y --no-install-recommends git build-essential && \ | ||
| rm -rf /var/lib/apt/lists/* && \ | ||
| git clone --recursive https://github.com/pytorch/FBGEMM.git /tmp/FBGEMM && \ | ||
| cd /tmp/FBGEMM && \ | ||
| git checkout 10b775730212923f65f7b78f79b6a01d80cf3c29 && \ | ||
| git submodule update --init --recursive && \ | ||
| cd fbgemm_gpu && \ | ||
| # Filter `fairscale` and the torch family from fbgemm's requirements.txt: | ||
| # fairscale pulls a CPU torch that would clobber the +rocm7.2 wheel installed | ||
| # above. fairscale is a distributed-training lib used by fbgemm tests, not | ||
| # by the build itself. | ||
| grep -v -E '^(fairscale|torch|torchvision|torchaudio)([<>=!]|$)' requirements.txt > /tmp/req.txt && \ | ||
| pip install -r /tmp/req.txt && \ | ||
| python setup.py -j 32 bdist_wheel \ | ||
| --build-target=default \ | ||
| --build-variant=rocm \ | ||
| -DHIP_ROOT_DIR=/opt/rocm \ | ||
| -DAMDGPU_TARGETS=gfx950 && \ | ||
| pip install --force-reinstall --no-deps dist/fbgemm_gpu_nightly_rocm*.whl && \ | ||
| cd / && rm -rf /tmp/FBGEMM | ||
|
|
||
| # polars-u64-idx — training_recipe.md:44 (mandatory; yambda-5b > 4.29 B rows). | ||
| # Remaining packages — training_recipe.md:156-159 ("Additional Python deps") plus | ||
| # `datasets` + `huggingface_hub`, which the recipe does not list but | ||
| # preprocess_public_data.py:278 imports to download yambda from HuggingFace. | ||
| RUN pip install \ | ||
| polars-u64-idx==1.33.1 \ | ||
| gin-config \ | ||
| absl-py \ | ||
| datasets \ | ||
| huggingface_hub \ | ||
| pyre-extensions \ | ||
| iopath \ | ||
| typing-inspect \ | ||
| psutil \ | ||
| tqdm \ | ||
| pyyaml \ | ||
| lightning-utilities && \ | ||
| # torchmetrics and tensordict declare `torch` as a dep; without --no-deps | ||
| # pip pulls torch==2.12.0+cu130 from PyPI which clobbers the +rocm7.2 wheel | ||
| # we installed above (libtorch_hip.so disappears, fbgemm_gpu fails to load). | ||
| pip install --no-deps \ | ||
| torchmetrics==1.0.3 \ | ||
| tensordict | ||
|
|
||
| # mlperf_logging — required by train/mlperf_logging_utils.py for MLPerf | ||
| # compliance logs. Pinned to the Training 6.0 tag for reproducibility; --no-deps | ||
| # so pip does not resolve requirements.txt's torch/fbgemm_gpu/torchrec pins and | ||
| # clobber the +rocm7.2 wheels above. | ||
| RUN pip install --no-deps "git+https://github.com/mlcommons/logging.git@6.0.0-rc6" | ||
|
|
||
| # Smoke-test the 6 imports the launch script checks at | ||
| # scripts/launch_smoke_8gpu.sh:26. | ||
| RUN python -c "import torch, fbgemm_gpu, torchrec, polars, xxhash, gin; \ | ||
| print('torch', torch.__version__, '| hip', getattr(torch.version, 'hip', None))" | ||
|
|
||
| COPY . /workspace/recommendation | ||
|
|
||
| ENV PYTORCH_CUDA_ALLOC_CONF=expandable_segments:True \ | ||
| HSTU_HAMMER_KERNEL=TRITON \ | ||
| DLRM_DATA_PATH=/data/mlperf_dlrm_v4 | ||
|
|
||
| CMD ["bash"] | ||
Oops, something went wrong.
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.
Is there a reason we are using nightly in the Dockerfile instead of 1.7.0 from the requirements.txt?
Uh oh!
There was an error while loading. Please reload this page.
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.
@pavanky in short, that is because there is no prebuilt gfx950/ROCm 7.2 wheel for fbgemm_gpu
documented this explicitly in the Dockerfile comment above the build, and added a matching note in requirements.txt clarifying that the ==1.7.0 pin applies only to prebuilt-wheel (CUDA/CPU) environments and is superseded by the source build on ROCm.