Skip to content

Commit

Permalink
Merge pull request #58 from graphcore-research/umup-updates
Browse files Browse the repository at this point in the history
Updates to support u-muP, as the new default behaviour
  • Loading branch information
DouglasOrr authored Jul 24, 2024
2 parents 0a6c9af + 357b2fb commit 087133f
Show file tree
Hide file tree
Showing 25 changed files with 2,590 additions and 327 deletions.
7 changes: 3 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
# Unit Scaling
# Unit-Scaled Maximal Update Parameterization (u-μP)

A library for unit scaling in PyTorch, based on the paper
[Unit Scaling: Out-of-the-Box Low-Precision Training](https://arxiv.org/abs/2303.11257).
A library for unit scaling in PyTorch, based on the paper [Unit-Scaled Maximal Update Parametrization](https://openreview.net/forum?id=44NKKzz1n5) and previous work [Unit Scaling: Out-of-the-Box Low-Precision Training](https://arxiv.org/abs/2303.11257).

Documentation can be found at
[https://graphcore-research.github.io/unit-scaling](https://graphcore-research.github.io/unit-scaling).
[https://graphcore-research.github.io/unit-scaling](https://graphcore-research.github.io/unit-scaling) and an example notebook at [examples/demo.ipynb](examples/demo.ipynb).

**Note:** The library is currently in its _beta_ release.
Some features have yet to be implemented and occasional bugs may be present.
Expand Down
243 changes: 243 additions & 0 deletions analysis/empirical_op_scaling.ipynb

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion dev
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,8 @@ def format(check: bool) -> None:
def copyright() -> None:
"""check for Graphcore copyright headers on relevant files"""
command = (
f"find {' '.join(PYTHON_ROOTS)} -type f -not -name *.pyc"
f"find {' '.join(PYTHON_ROOTS)} -type f"
" -not -name *.pyc -not -name *.json -not -name .gitignore"
" | xargs grep -L 'Copyright (c) 202. Graphcore Ltd[.] All rights reserved[.]'"
)
print(f"$ {command}", file=sys.stderr)
Expand Down
2 changes: 2 additions & 0 deletions docs/api_reference.rst
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,9 @@ Click below for the full documentation:
unit_scaling.constraints
unit_scaling.formats
unit_scaling.functional
unit_scaling.optim
unit_scaling.scale
unit_scaling.transforms
unit_scaling.transforms.utils
unit_scaling.utils
unit_scaling.core.functional
1 change: 1 addition & 0 deletions examples/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*.json
Loading

0 comments on commit 087133f

Please sign in to comment.