Skip to content

Commit 0a16282

Browse files
committed
lints
Signed-off-by: Ananth Subramaniam <ansubramania@nvidia.com>
1 parent 5e5fd2a commit 0a16282

File tree

3 files changed

+5
-6
lines changed

3 files changed

+5
-6
lines changed

examples/llm/llama3_8b/conf/llama3_8b_pretrain_override_example.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,4 +56,4 @@ profiling_config:
5656
profile_step_start: 1000
5757
profile_step_end: 10000
5858
use_pytorch_profiler: true
59-
profile_ranks: [0, 1]
59+
profile_ranks: [0, 1]

examples/llm/llama3_8b/pretrain_llama3_8b.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@
1515

1616
import argparse
1717
import dataclasses
18+
import logging
1819
import os
1920
import sys
20-
import logging
2121
from typing import Any, Dict, TypeVar
2222

23-
from omegaconf import OmegaConf, DictConfig
23+
from omegaconf import DictConfig, OmegaConf
2424

2525
from nemo_lm.models.utils import forward_step
2626
from nemo_lm.recipes.llm.llama3_8b import pretrain_config
@@ -60,6 +60,7 @@ def apply_overrides_recursively(config_obj: DataclassInstance, overrides_dict: D
6060

6161

6262
def main() -> None:
63+
"""Entry point for the script."""
6364
parser = argparse.ArgumentParser(description="Pretrain Llama3 8B model using NeMo-LM")
6465
parser.add_argument(
6566
"--config-file",
@@ -74,7 +75,6 @@ def main() -> None:
7475
logger.info("------------------------------------")
7576

7677
# 1. Load base configuration from the recipe - this is our primary Python object
77-
logger.info(f"Loading base configuration using 'pretrain_config' from nemo_lm.recipes.llm.llama3_8b...")
7878
final_cfg_container: ConfigContainer = pretrain_config()
7979

8080
# 2. Load YAML overrides into an OmegaConf dictionary

nemo_lm/recipes/llm/llama3_8b.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15+
import os
1516
from typing import Optional
1617

17-
import os
1818
import torch
1919

2020
from megatron.core.distributed import DistributedDataParallelConfig
@@ -24,7 +24,6 @@
2424
from nemo_lm.training.config import (
2525
CheckpointConfig,
2626
ConfigContainer,
27-
FinetuningDatasetConfig,
2827
GPTDatasetConfig,
2928
LoggerConfig,
3029
RNGConfig,

0 commit comments

Comments
 (0)