Lightning-AI / Lightning-AI/lightning-thunder

Torch compile support for distributed operations

Open
#1,146 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement triage review
Dominant language
Python
Stars
1.5k
Forks
121
PR merge metrics
No merged PRs in 30d

Description

## 🚀 Feature

[Documentation says](https://lightning.ai/docs/pytorch/latest/advanced/compile.html#limitations) that torch compile is not supported over distributed training right now. Since torch compile can speed up training as much as 2x using Lightning Trainer is without compile is no longer cost efficient and it would be great to support it.

It's bit unclear to me what happens if I compile the model before passing to Lightning module, will it be used as compiled model over DDP or not?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the torch compile limitations documentation linked in the issue and investigate how a model compiled before being passed to the Lightning module behaves under DDP. Define and verify what distributed-operation support should cover, then update the documentation or implementation with evidence that compiled models work during distributed training.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, pytorch
Domain
distributed-systems, machine-learning
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.