Skip to content

Commit

Permalink
Add megatron_core to requirements (#6639)
Browse files Browse the repository at this point in the history
* add megatron_core to requirements

Signed-off-by: ericharper <[email protected]>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Signed-off-by: ericharper <[email protected]>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
  • Loading branch information
2 people authored and web-flow committed May 11, 2023
1 parent 149f02f commit 1c46e60
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 16 deletions.
5 changes: 0 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,6 @@ RUN apt-get update && \
rm -rf /var/lib/apt/lists/*

WORKDIR /workspace/
# Install Megatron-core
RUN git clone https://github.com/NVIDIA/Megatron-LM.git && \
cd Megatron-LM && \
git checkout 9f8bdeb4814ed61fbc9c7d5b39c7710e77b99754 && \
pip install -e .

WORKDIR /tmp/
# TODO: Remove once this Apex commit (2/24/23) is included in PyTorch
Expand Down
13 changes: 2 additions & 11 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -236,8 +236,8 @@ Note that RNNT requires numba to be installed from conda.
NeMo Megatron
~~~~~~~~~~~~~
NeMo Megatron training requires NVIDIA Apex and Megatron-core to be installed.
Install them manually if not using the NVIDIA PyTorch container.
NeMo Megatron training requires NVIDIA Apex to be installed.
Install it manually if not using the NVIDIA PyTorch container.

To install Apex, run

Expand All @@ -248,15 +248,6 @@ To install Apex, run
git checkout 57057e2fcf1c084c0fcc818f55c0ff6ea1b24ae2
pip install -v --disable-pip-version-check --no-cache-dir --global-option="--cpp_ext" --global-option="--cuda_ext" --global-option="--fast_layer_norm" --global-option="--distributed_adam" --global-option="--deprecated_fused_adam" ./
To install Megatron-core, run

.. code-block:: bash
git clone https://github.com/NVIDIA/Megatron-LM.git
cd Megatron-LM
git checkout 9f8bdeb4814ed61fbc9c7d5b39c7710e77b99754
pip install -e .
It is highly recommended to use the NVIDIA PyTorch or NeMo container if having issues installing Apex or any other dependencies.

While installing Apex, it may raise an error if the CUDA version on your system does not match the CUDA version torch was compiled with.
Expand Down
1 change: 1 addition & 0 deletions requirements/requirements_nlp.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ ijson
inflect
jieba
matplotlib>=3.3.2
megatron_core==0.1.0
nltk>=3.6.5
numpy
opencc
Expand Down

0 comments on commit 1c46e60

Please sign in to comment.