Skip to content
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ _**Note**, even if you do not find the solution, sending a PR with a test coveri

Want to keep Lightning healthy? Love seeing those green tests? So do we! How to we keep it that way? We write tests! We value tests contribution even more than new features.

Most of the tests in PyTorch Lightning train a random `BoringModel` under various trainer conditions (ddp, amp, etc...). Want to add a new test case and not sure how? [Talk to us!](https://www.pytorchlightning.ai/community)
Most of the tests in PyTorch Lightning train a random `BoringModel` under various trainer conditions (ddp, amp, etc...). Want to add a new test case and not sure how? [Talk to us!](https://www.lightning.ai/community)
Comment thread
deependujha marked this conversation as resolved.
Resolved

______________________________________________________________________

Expand Down
2 changes: 1 addition & 1 deletion docs/source-fabric/_templates/theme_variables.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
'get_started': '',
'blog': 'https://lightning.ai/pages/blog/',
'support': '',
'community': 'https://www.pytorchlightning.ai/community',
'community': 'https://www.lightning.ai/community',
'forums': 'https://lightning.ai/forums/',
}
-%}
4 changes: 2 additions & 2 deletions docs/source-fabric/fundamentals/precision.rst
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ memory utilization in both training and inference. It offers improved performanc

Using TE requires replacing some of the layers in your model. Fabric automatically replaces the :class:`torch.nn.Linear`
and :class:`torch.nn.LayerNorm` layers in your model with their TE alternatives, however, TE also offers
`fused layers <https://docs.nvidia.com/deeplearning/transformer-engine/user-guide/api/pytorch.html>`__
`fused layers <https://docs.nvidia.com/deeplearning/transformer-engine/api/pytorch.html>`__
to squeeze out all the possible performance. If Fabric detects that any layer has been replaced already, automatic
replacement is not done.

Expand All @@ -162,7 +162,7 @@ the model and inputs can be kept in true full or half precision.
fabric = Fabric(plugins=precision)


Under the hood, we use `transformer_engine.pytorch.fp8_autocast <https://docs.nvidia.com/deeplearning/transformer-engine/user-guide/api/pytorch.html#transformer_engine.pytorch.fp8_autocast>`__ with the default fp8 recipe.
Under the hood, we use `transformer_engine.pytorch.fp8_autocast <https://docs.nvidia.com/deeplearning/transformer-engine/api/pytorch.html#transformer_engine.pytorch.fp8_autocast>`__ with the default fp8 recipe.

.. note::

Expand Down
4 changes: 2 additions & 2 deletions docs/source-pytorch/_templates/theme_variables.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@
'governance': 'https://lightning.ai/docs/pytorch/latest/community/governance.html',
'docs': 'https://lightning.ai/docs/pytorch/latest/',
'twitter': 'https://twitter.com/LightningAI',
'discuss': 'https://www.pytorchlightning.ai/community',
'discuss': 'https://www.lightning.ai/community',
'tutorials': 'https://lightning.ai/docs/pytorch/latest/#tutorials',
'home': 'https://lightning.ai/docs/pytorch/latest/',
'get_started': 'https://lightning.ai/docs/pytorch/latest/starter/introduction.html',
'features': 'https://lightning.ai/docs/pytorch/latest/',
'blog': 'https://lightning.ai/pages/blog/',
'resources': 'https://lightning.ai/docs/pytorch/latest/#community-examples',
'support': 'https://lightning.ai/docs/pytorch/latest/',
'community': 'https://www.pytorchlightning.ai/community',
'community': 'https://www.lightning.ai/community',
'forums': 'https://lightning.ai/forums/',
'versions': 'https://lightning.ai/docs/pytorch/latest/past_versions.html'
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ DeepSpeed

`DeepSpeed <https://github.com/microsoft/DeepSpeed>`__ is a deep learning training optimization library, providing the means to train massive billion parameter models at scale.
Using the DeepSpeed strategy, we were able to **train model sizes of 10 Billion parameters and above**, with a lot of useful information in this `benchmark <https://github.com/huggingface/transformers/issues/9996>`_ and the `DeepSpeed docs <https://www.deepspeed.ai/tutorials/megatron/>`__.
DeepSpeed also offers lower level training optimizations, and efficient optimizers such as `1-bit Adam <https://www.deepspeed.ai/tutorials/onebit-adam/>`_. We recommend using DeepSpeed in environments where speed and memory optimizations are important (such as training large billion parameter models).
DeepSpeed also offers lower level training optimizations, and efficient optimizers. We recommend using DeepSpeed in environments where speed and memory optimizations are important (such as training large billion parameter models).

.. warning:: This is an :ref:`experimental <versioning:Experimental API>` feature.

Expand Down
4 changes: 2 additions & 2 deletions docs/source-pytorch/common/precision_intermediate.rst
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ memory utilization in both training and inference. It offers improved performanc

Using TE requires replacing some of the layers in your model. Fabric automatically replaces the :class:`torch.nn.Linear`
and :class:`torch.nn.LayerNorm` layers in your model with their TE alternatives, however, TE also offers
`fused layers <https://docs.nvidia.com/deeplearning/transformer-engine/user-guide/api/pytorch.html>`__
`fused layers <https://docs.nvidia.com/deeplearning/transformer-engine/api/pytorch.html>`__
to squeeze out all the possible performance. If Fabric detects that any layer has been replaced already, automatic
replacement is not done.

Expand All @@ -151,7 +151,7 @@ the model and inputs can be kept in true full or half precision.
trainer = Trainer(plugins=precision)


Under the hood, we use `transformer_engine.pytorch.fp8_autocast <https://docs.nvidia.com/deeplearning/transformer-engine/user-guide/api/pytorch.html#transformer_engine.pytorch.fp8_autocast>`__ with the default fp8 recipe.
Under the hood, we use `transformer_engine.pytorch.fp8_autocast <https://docs.nvidia.com/deeplearning/transformer-engine/api/pytorch.html#transformer_engine.pytorch.fp8_autocast>`__ with the default fp8 recipe.

.. note::

Expand Down
2 changes: 1 addition & 1 deletion examples/pytorch/bug_report/bug_report_model.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
"# The Boring Model\n",
"Replicate a bug you experience, using this model.\n",
"\n",
"[Remember! we're always available for support on Slack](https://www.pytorchlightning.ai/community)"
"[Remember! we're always available for support on Slack](https://www.lightning.ai/community)"
]
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ class TransformerEnginePrecision(Precision):
Args:
weights_dtype: The weights dtype to use.
recipe: Recipe for the DelayedScaling
`configuration <https://docs.nvidia.com/deeplearning/transformer-engine/user-guide/api/common.html#transformer_engine.common.recipe.DelayedScaling>`__.
`configuration <https://docs.nvidia.com/deeplearning/transformer-engine/api/common.html#transformer_engine.common.recipe.DelayedScaling>`__.
In dict format or the dataclass format.
replace_layers: Whether to replace ``Linear`` and ``LayerNorm`` layers automatically with their Transformer
Engine alternatives. Note that they don't subclass the torch equivalents so checks like
Expand Down Expand Up @@ -154,7 +154,7 @@ def _convert_layers(module: torch.nn.Module) -> None:
for name, child in module.named_children():
if isinstance(child, torch.nn.Linear):
if child.in_features % 8 != 0 or child.out_features % 16 != 0:
# https://docs.nvidia.com/deeplearning/transformer-engine/user-guide/examples/fp8_primer.html#FP8-autocasting
# https://docs.nvidia.com/deeplearning/transformer-engine/examples/fp8_primer.html#FP8-autocasting
rank_zero_warn(
"Support for FP8 in the linear layers with this plugin is currently limited to"
" tensors with shapes where the dimensions are divisible by 8 and 16 respectively."
Expand All @@ -178,5 +178,5 @@ def _convert_layers(module: torch.nn.Module) -> None:
module.__setattr__(name, replacement)
else:
# there are other transformer engine layers that we could convert but require fusion. full list at:
# https://docs.nvidia.com/deeplearning/transformer-engine/user-guide/api/pytorch.html
# https://docs.nvidia.com/deeplearning/transformer-engine/api/pytorch.html
_convert_layers(child)
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class TransformerEnginePrecision(Precision, FabricTEPrecision):
Args:
dtype: The weights dtype to use.
recipe: Recipe for the DelayedScaling
`configuration <https://docs.nvidia.com/deeplearning/transformer-engine/user-guide/api/common.html#transformer_engine.common.recipe.DelayedScaling>`__.
`configuration <https://docs.nvidia.com/deeplearning/transformer-engine/api/common.html#transformer_engine.common.recipe.DelayedScaling>`__.
In dict format or the dataclass format.
replace_layers: Whether to replace ``Linear`` and ``LayerNorm`` layers automatically with their Transformer
Engine alternatives. Note that they don't subclass the torch equivalents so checks like
Expand Down
2 changes: 1 addition & 1 deletion tests/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# PyTorch-Lightning Tests

Most of the tests in PyTorch Lightning train a [BoringModel](https://github.com/Lightning-AI/pytorch-lightning/blob/master/src/lightning/pytorch/demos/boring_classes.py) under various trainer conditions (ddp, amp, etc...). Want to add a new test case and not sure how? [Talk to us!](https://www.pytorchlightning.ai/community)
Most of the tests in PyTorch Lightning train a [BoringModel](https://github.com/Lightning-AI/pytorch-lightning/blob/master/src/lightning/pytorch/demos/boring_classes.py) under various trainer conditions (ddp, amp, etc...). Want to add a new test case and not sure how? [Talk to us!](https://www.lightning.ai/community)

## Running tests

Expand Down
Loading