Skip to content

Use Liger v4 for tiled MLP training on CUDA and ROCm - #5

Open
kashif wants to merge 2 commits into
vasqu:kernels-swi-geglufrom
kashif:rocm-tiled-mlp-for-48335
Open

kashif wants to merge 2 commits into
vasqu:kernels-swi-geglufrom
kashif:rocm-tiled-mlp-for-48335

Conversation

@kashif

@kashif kashif commented Nov 24, 2026 •

Copy link
Copy Markdown

What does this PR do?

Uses Liger v4 for LigerTiledSwiGLUMLP and LigerTiledGEGLUMLP training on CUDA and ROCm on the branch for huggingface#48335. The published v4 builds include huggingface/kernels-community#1340.

Testing

  • make style passed on this branch.
  • On Transformers main with [Kernels] Add swiglu and geglu MLP across models huggingface/transformers#48335’s model hooks applied, use_kernels=True selected both kernels on gfx1150. BF16 forward and backward passed with frozen embeddings in Qwen3 and Gemma.
  • Verified that the published CUDA v4 build exports both tiled layers and includes the merged tiled_mlp.py.
  • The current base branch fails during model import with kernels==0.16.2. Its decorator wrapper passes condition, and that release accepts only layer_name.

@kashif kashif changed the title Enable Liger tiled MLP training on ROCm Use Liger v4 for tiled MLP training on CUDA and ROCm Nov 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant