Skip to content

Commit c8a4316

Browse files
authored
Use latest pytorch-lightning version (#926)
Previously, we had fixed the version to an earlier release, which became incompatible after pip updated to 24.1. So, we took this opportunity to update it to the latest version.
1 parent 9c509c1 commit c8a4316

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

dev-requirements.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@ pyre-extensions
2020
pyre-check
2121
pytest
2222
pytest-cov
23-
pytorch-lightning==1.5.10
23+
pytorch-lightning==2.3.1
24+
tensorboard==2.14.0
2425
sagemaker>=2.149.0
2526
torch-model-archiver>=0.4.2
2627
torch==2.2.1

torchx/examples/apps/lightning/profiler.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,18 +19,19 @@
1919
import time
2020
from typing import Dict
2121

22-
from pytorch_lightning.loggers.base import LightningLoggerBase
23-
from pytorch_lightning.profiler.base import BaseProfiler
22+
from pytorch_lightning.loggers.logger import Logger
2423

24+
from pytorch_lightning.profilers.profiler import Profiler
2525

26-
class SimpleLoggingProfiler(BaseProfiler):
26+
27+
class SimpleLoggingProfiler(Profiler):
2728
"""
2829
This profiler records the duration of actions (in seconds) and reports the
2930
mean duration of each action to the specified logger. Reported metrics are
3031
in the format `duration_<event>`.
3132
"""
3233

33-
def __init__(self, logger: LightningLoggerBase) -> None:
34+
def __init__(self, logger: Logger) -> None:
3435
super().__init__()
3536

3637
self.current_actions: Dict[str, float] = {}

0 commit comments

Comments
 (0)