Skip to content

Commit

Permalink
Release 2.2.1
Browse files Browse the repository at this point in the history
  • Loading branch information
awaelchli authored and lantiga committed Mar 4, 2024
1 parent 273650f commit 093fac1
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 11 deletions.
2 changes: 2 additions & 0 deletions docs/source-pytorch/conf.py
Expand Up @@ -624,4 +624,6 @@ def package_list_from_file(file):
"https://www.intel.com/content/www/us/en/products/docs/processors/what-is-a-gpu.html",
"https://www.microsoft.com/en-us/research/blog/zero-infinity-and-deepspeed-unlocking-unprecedented-model-scale-for-deep-learning-training/", # noqa: E501
"https://stackoverflow.com/questions/66640705/how-can-i-install-grpcio-on-an-apple-m1-silicon-laptop",
"https://github.com/Lightning-AI/lightning/blob/master/examples/pytorch/ipu/mnist_sample.py",
"https://ngc.nvidia.com/catalog/containers/nvidia:nemo", # in ecosystem/asr_nlp_tts.rst
]
4 changes: 2 additions & 2 deletions src/lightning/app/core/app.py
Expand Up @@ -371,9 +371,9 @@ def _collect_deltas_from_ui_and_work_queues(self) -> List[Union[Delta, _APIReque

if work:
delta = _delta_to_app_state_delta(
self.root,
self.root, # type: ignore[arg-type]
work,
deepcopy(delta.delta), # type: ignore[arg-type]
deepcopy(delta.delta),
)
deltas.append(delta)
else:
Expand Down
6 changes: 3 additions & 3 deletions src/lightning/data/processing/dns.py
Expand Up @@ -25,11 +25,11 @@ def optimize_dns(enable: bool) -> None:

if (enable and any("127.0.0.53" in line for line in lines)) or (
not enable and any("127.0.0.1" in line for line in lines)
): # noqa E501
): # E501
Popen(
f"sudo /home/zeus/miniconda3/envs/cloudspace/bin/python -c 'from lightning.data.processing.dns import _optimize_dns; _optimize_dns({enable})'",
f"sudo /home/zeus/miniconda3/envs/cloudspace/bin/python -c 'from lightning.data.processing.dns import _optimize_dns; _optimize_dns({enable})'", # noqa E501
shell=True,
).wait() # noqa E501
).wait()


def _optimize_dns(enable: bool) -> None:
Expand Down
4 changes: 2 additions & 2 deletions src/lightning/fabric/strategies/fsdp.py
Expand Up @@ -927,7 +927,7 @@ def _distributed_checkpoint_save(converted_state: Dict[str, Any], path: Path) ->

# let torch automatically infer the writer to use. This might also support fsspec paths in the future
# https://github.com/pytorch/pytorch/issues/118036
save(converted_state, checkpoint_id=path) # type: ignore[call-arg]
save(converted_state, checkpoint_id=path)
else: # deprecated
from torch.distributed.checkpoint import FileSystemWriter

Expand All @@ -946,7 +946,7 @@ def _distributed_checkpoint_load(module_state: Dict[str, Any], path: Path) -> No

# let torch automatically infer the reader to use. This might also support fsspec paths in the future
# https://github.com/pytorch/pytorch/issues/118036
load(module_state, checkpoint_id=path) # type: ignore[call-arg]
load(module_state, checkpoint_id=path)
else: # deprecated
from torch.distributed.checkpoint import FileSystemReader

Expand Down
2 changes: 1 addition & 1 deletion src/lightning/pytorch/loggers/neptune.py
Expand Up @@ -403,7 +403,7 @@ def run(self) -> "Run":
@override
@rank_zero_only
@_catch_inactive
def log_hyperparams(self, params: Union[Dict[str, Any], Namespace]) -> None: # type: ignore[override]
def log_hyperparams(self, params: Union[Dict[str, Any], Namespace]) -> None:
r"""Log hyperparameters to the run.
Hyperparameters will be logged under the "<prefix>/hyperparams" namespace.
Expand Down
2 changes: 1 addition & 1 deletion src/version.info
@@ -1 +1 @@
2.2.0.post0
2.2.1
4 changes: 2 additions & 2 deletions tests/tests_data/processing/test_dns.py
Expand Up @@ -31,5 +31,5 @@ def readlines(self):
cmd = popen_mock._mock_call_args_list[0].args[0]
assert (
cmd
== "sudo /home/zeus/miniconda3/envs/cloudspace/bin/python -c 'from lightning.data.processing.dns import _optimize_dns; _optimize_dns(True)'"
) # noqa: E501
== "sudo /home/zeus/miniconda3/envs/cloudspace/bin/python -c 'from lightning.data.processing.dns import _optimize_dns; _optimize_dns(True)'" # noqa: E501
)

0 comments on commit 093fac1

Please sign in to comment.