Skip to content

Commit 8890699

Browse files
authored
Merge branch 'master' into feature/fsdp-cpu
2 parents fa1458a + 21ac841 commit 8890699

17 files changed

Lines changed: 158 additions & 48 deletions

File tree

.lightning/workflows/pytorch.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -122,10 +122,11 @@ run: |
122122
echo "Install package"
123123
extra=$(python -c "print({'lightning': 'pytorch-'}.get('${PACKAGE_NAME}', ''))")
124124
125-
# Use find-links to prefer CUDA-specific packages from PyTorch index
125+
# Prefer CUDA-specific builds from the PyTorch index.
126+
# torch-tensorrt is intentionally left to PyPI: since 2.13.0 its `+cuXXX` wheels no longer
127+
# bundle `libtorchtrt.so`, which silently disables the TorchScript frontend.
126128
uv pip install -e ".[${extra}dev,${extra}test_gpu]" --upgrade \
127-
--find-links="https://download.pytorch.org/whl/${UV_TORCH_BACKEND}" \
128-
--find-links="https://download.pytorch.org/whl/${UV_TORCH_BACKEND}/torch-tensorrt"
129+
--find-links="https://download.pytorch.org/whl/${UV_TORCH_BACKEND}"
129130
uv pip list
130131
131132
echo "Ensure only a single package is installed"

docs/source-pytorch/versioning.rst

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,18 @@ Since the release of PyTorch `2.0`, Lightning strives to officially support the
8383
- ``torch``
8484
- ``torchmetrics``
8585
- Python
86+
* - 2.7
87+
- 2.7
88+
- 2.7
89+
- ≥2.6 (▼ 2.13)
90+
- ≥0.7.0
91+
- ≥3.10 (▼ 3.13)
92+
* - 2.6
93+
- 2.6
94+
- 2.6
95+
- ≥2.1 (▼ 2.10)
96+
- ≥0.7.0
97+
- ≥3.10 (▼ 3.13)
8698
* - 2.5
8799
- 2.5
88100
- 2.5

pyproject.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,9 @@ filterwarnings = [
177177
# deprecated in torch 2.12; the suggested replacement is a private API
178178
# TODO: migrate to torch.distributed._functional_collectives.all_gather_single for torch>=2.12
179179
"ignore:torch.distributed.nn.functional.all_gather is deprecated.*:FutureWarning",
180+
# torch 2.13 renamed these collectives to their `_single` counterparts; DeepSpeed still calls the old names
181+
"ignore:`torch.distributed.all_gather_into_tensor` is deprecated.*:FutureWarning",
182+
"ignore:`torch.distributed.reduce_scatter_tensor` is deprecated.*:FutureWarning",
180183
# PyTorch pytree LeafSpec deprecation triggered during doctest
181184
"ignore:`isinstance\\(treespec, LeafSpec\\)` is deprecated.*:FutureWarning",
182185
]

requirements/fabric/base.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# NOTE: the upper bound for the package version is only set for CI stability, and it is dropped while installing this package
22
# in case you want to preserve/enforce restrictions on the latest compatible version, add "strict" as an in-line comment
33

4-
torch >=2.6.0, <2.13.0
4+
torch >=2.6.0, <2.14.0
55
fsspec[http] >=2022.5.0, <2026.4.0
66
packaging >=23.0, <=26.0
77
typing-extensions >4.5.0, <4.16.0

requirements/pytorch/base.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# NOTE: the upper bound for the package version is only set for CI stability, and it is dropped while installing this package
22
# in case you want to preserve/enforce restrictions on the latest compatible version, add "strict" as an in-line comment
33

4-
torch >=2.6.0, <2.13.0
4+
torch >=2.6.0, <2.14.0
55
tqdm >=4.57.0, <4.68.0
66
PyYAML >5.4, <6.1.0
77
fsspec[http] >=2022.5.0, <2026.4.0

requirements/pytorch/extra.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
matplotlib>3.1, <3.11.0
66
omegaconf >=2.2.3, <2.4.0
77
hydra-core >=1.2.0, <1.4.0
8-
jsonargparse[signatures,jsonnet] >=4.39.0, <4.48.0
8+
jsonargparse[signatures,jsonnet] >=4.39.0, <4.51.0
99
rich >=12.3.0, <14.4.0
1010
tensorboardX >=2.2, <2.7.0 # min version is set by torch.onnx missing attribute
1111
bitsandbytes >=0.45.2,<0.50.0; platform_system != "Darwin"

src/lightning/fabric/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
3636

3737
- Fixed AccumulateGrad stream mismatch warning when using DDP with Fabric ([#21746](https://github.com/Lightning-AI/pytorch-lightning/pull/21746))
3838

39+
- Fixed `_atomic_save` swallowing `PermissionError`, which made checkpoint saving report success without writing a file ([#21799](https://github.com/Lightning-AI/pytorch-lightning/pull/21799))
40+
3941
---
4042

4143
## [2.6.4] - 2026-05-20

src/lightning/fabric/utilities/cloud_io.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,7 @@ def _atomic_save(checkpoint: dict[str, Any], filepath: _PATH) -> None:
130130
raise RuntimeError(
131131
'Upgrade fsspec to enable cross-device local checkpoints: pip install "fsspec[http]>=2025.5.0"',
132132
) from e
133+
raise
133134

134135

135136
def _is_object_storage(fs: AbstractFileSystem) -> bool:

src/lightning/pytorch/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,10 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
3737

3838
### Fixed
3939

40+
- Fixed `LightningCLI` emitting `jsonargparse` deprecation warnings ([#21900](https://github.com/Lightning-AI/pytorch-lightning/issues/21900))
41+
42+
- Fixed `RichProgressBar` showing a nonsensical negative epoch total (e.g. `Epoch 5/-2`) when `Trainer(max_epochs=-1)` (unlimited epochs) is used and training stops via another condition ([#21925](https://github.com/Lightning-AI/pytorch-lightning/issues/21925))
43+
4044
- Fixed crash when calling ``self.log()`` inside a ``torch.compile``-wrapped ``LightningModule`` on PyTorch 2.12/2.13 by disabling Dynamo tracing at the ``LightningModule.log`` boundary ([#21836](https://github.com/Lightning-AI/pytorch-lightning/issues/21836))
4145

4246
- Fixed PyTorch Lightning profiler not capturing dataloader worker initialization time ([#21771](https://github.com/Lightning-AI/pytorch-lightning/issues/21771))

src/lightning/pytorch/callbacks/progress/rich_progress.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -655,7 +655,7 @@ def on_predict_batch_end(
655655

656656
def _get_train_description(self, current_epoch: int) -> str:
657657
train_description = f"Epoch {current_epoch}"
658-
if self.trainer.max_epochs is not None:
658+
if self.trainer.max_epochs is not None and self.trainer.max_epochs >= 0:
659659
train_description += f"/{self.trainer.max_epochs - 1}"
660660
if len(self.validation_description) > len(train_description):
661661
# Padding is required to avoid flickering due of uneven lengths of "Epoch X"

0 commit comments

Comments
 (0)