Skip to content

Commit 881b8ed

Browse files
danielsuoFlax Authors
authored andcommitted
[flax:examples:lm1b_nnx] Update example to work internally. #jax-fixit.
PiperOrigin-RevId: 840808821
1 parent ec85cdd commit 881b8ed

17 files changed

+3
-2917
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ comes with everything you need to start your research, including:
6262

6363
* **Utilities and patterns**: replicated training, serialization and checkpointing, metrics, prefetching on device.
6464

65-
* **Educational examples**: [MNIST](https://flax.readthedocs.io/en/latest/mnist_tutorial.html), [Inference/sampling with the Gemma language model (transformer)](https://github.com/google/flax/tree/main/examples/gemma), [Transformer LM1B](https://github.com/google/flax/tree/main/examples/lm1b_nnx).
65+
* **Educational examples**: [MNIST](https://flax.readthedocs.io/en/latest/mnist_tutorial.html), [Inference/sampling with the Gemma language model (transformer)](https://github.com/google/flax/tree/main/examples/gemma).
6666

6767
## Quick install
6868

examples/gemma/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
## Language modeling
33
Trains Gemma model on the One Billion Word Benchmark (lm1b; Chelba *et al.*, 2013).
44

5-
This example is based on `lm1b_nnx` example script and similarly uses linear learning rate warmup and inverse square root learning rate schedule.
5+
This example is based on lm1b and similarly uses linear learning rate warmup and inverse square root learning rate schedule.
66

77

88
### Requirements

examples/gemma/input_pipeline_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def _get_datasets(self):
4949
vocab_path = os.path.join(tempfile.mkdtemp(), 'sentencepiece_model')
5050

5151
# Go two directories up to the root of the flax directory.
52-
# "/path/to/flax/examples/lm1b_nnx/models_test.py" -> "/path/to/flax"
52+
# "/path/to/flax/examples/gemma/input_pipeline_test.py" -> "/path/to/flax"
5353
flax_root_dir = pathlib.Path(__file__).absolute().parents[2]
5454
data_dir = str(flax_root_dir) + '/.tfds/metadata' # pylint: disable=unused-variable
5555

examples/lm1b_nnx/README.md

Lines changed: 0 additions & 91 deletions
This file was deleted.

examples/lm1b_nnx/configs/default.py

Lines changed: 0 additions & 141 deletions
This file was deleted.

0 commit comments

Comments
 (0)