You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/install_maxtext.md
+28-18Lines changed: 28 additions & 18 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -108,7 +108,7 @@ Please keep dependencies updated throughout development. This will allow each co
108
108
109
109
To update dependencies, you will follow these general steps:
110
110
111
-
1.**Modify Base Requirements**: Update the desired dependencies in `base_requirements/requirements.txt` or the hardware-specific files (`base_requirements/tpu-base-requirements.txt`, `base_requirements/gpu-base-requirements.txt`).
111
+
1.**Modify Base Requirements**: Update the desired dependencies in `base_requirements/requirements.txt` or the hardware-specific files (`base_requirements/tpu-requirements.txt`, `base_requirements/gpu-requirements.txt`).
112
112
2.**Generate New Files**: Run the `seed-env` CLI tool to generate new, fully-pinned requirements files based on your changes.
113
113
3.**Update Project Files**: Copy the newly generated files into the `generated_requirements/` directory.
114
114
4.**Handle GitHub Dependencies**: Move any dependencies that are installed directly from GitHub from the generated files to `src/dependencies/github_deps/pre_train_deps.txt`.
@@ -131,48 +131,58 @@ You can find the latest commit hashes in the [JAX `build/` folder](https://githu
131
131
132
132
Next, run the `seed-env` CLI to generate the new requirements files. You will need to do this separately for the TPU and GPU environments. The generated files will be placed in a directory specified by `--output-dir`.
133
133
134
-
### For TPU
134
+
> **Note:** The current `src/dependencies/requirements/generated_requirements/` in the repository were generated using JAX build commit: [e0d2967b50abbefd651d563dbcd7afbcb963d08c](https://github.com/jax-ml/jax/commit/e0d2967b50abbefd651d563dbcd7afbcb963d08c).
135
135
136
-
Run the following command, replacing `<jax-build-commit-hash>` with the hash you copied in the previous step.
136
+
### TPU Pre-Training
137
+
138
+
If you have made changes to the pre-training dependencies in `src/dependencies/requirements/base_requirements/tpu-requirements.txt`, you need to regenerate the pinned pre-training requirements in `generated_requirements/` directory. Run the following command, replacing `<jax-build-commit-hash>` with the hash you copied in the previous step:
After generating the new requirements, you need to copy the generated files from `generated_tpu_artifacts/tpu-requirements.txt` to `src/dependencies/requirements/generated_requirements/tpu-requirements.txt`.
151
+
152
+
#### TPU Post-Training
149
153
150
-
Similarly, run the command for the GPU requirements.
154
+
If you have made changes to the post-training dependencies in `src/dependencies/requirements/base_requirements/tpu-post-train-requirements.txt`, you need to regenerate the pinned post-training requirements in `generated_requirements/` directory. Run the following command, replacing `<jax-build-commit-hash>` with the hash you copied in the previous step:
After generating the new requirements, you need to copy the generated files from `generated_tpu_post_train_artifacts/tpu-post-train-requirements.txt` to `src/dependencies/requirements/generated_requirements/tpu-post-train-requirements.txt`.
164
167
165
-
After generating the new requirements, you need to update the files in the MaxText repository.
168
+
### GPU Pre-Training
166
169
167
-
1.**Copy the generated files:**
170
+
If you have made changes to the GPU pre-training dependencies in `src/dependencies/requirements/base_requirements/gpu-requirements.txt`, you need to regenerate the pinned pre-training requirements in `generated_requirements/` directory. Run the following command, replacing `<jax-build-commit-hash>` with the hash you copied in the previous step:
168
171
169
-
- Move `generated_tpu_artifacts/tpu-requirements.txt` to `generated_requirements/tpu-requirements.txt`.
170
-
- Move `generated_gpu_artifacts/cuda12-requirements.txt` to `generated_requirements/cuda12-requirements.txt`.
Currently, MaxText uses a few dependencies, such as `mlperf-logging` and `google-jetstream`, that are installed directly from GitHub source. These are defined in `base_requirements/requirements.txt`, and the `seed-env` tool will carry them over to the generated requirements files.
183
+
After generating the new requirements, you need to copy the generated files from `generated_gpu_artifacts/cuda12-requirements.txt` to `src/dependencies/requirements/generated_requirements/cuda12-requirements.txt`.
174
184
175
-
## Step 5: Verify the New Dependencies
185
+
## Step 4: Verify the New Dependencies
176
186
177
187
Finally, test that the new dependencies install correctly and that MaxText runs as expected.
0 commit comments