Skip to content

Commit 2a751ff

Browse files
committedFeb 19, 2025
fix
1 parent 3407aee commit 2a751ff

File tree

8 files changed

+8
-9
lines changed

8 files changed

+8
-9
lines changed
 

‎ci_scripts/train/load_ckpt.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ if [[ ! -f ${file} ]]; then
2222
exit_code=$(($exit_code + 1))
2323
fi
2424

25-
srun -p ${SLURM_PARTITION} --kill-on-bad-exit=1 --exclusive --job-name=$2 -n 8 --ntasks-per-node=8 --gpus-per-task=1 python internlm/launcher/launch.py --config ${file}
25+
srun -p ${SLURM_PARTITION} --kill-on-bad-exit=1 --exclusive --job-name=$2 -n 8 --ntasks-per-node=8 --gpus-per-task=1 python internlm/launch/launcher.py --config ${file}
2626
[[ $? -ne 0 ]] && { echo "test slurm training failed."; exit_code=$(($exit_code + 1)); }
2727

2828

‎ci_scripts/train/slurm_train.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ if [[ -d ${CKPTS20_PATH} ]]; then
2222
fi
2323
fi
2424

25-
srun -p ${SLURM_PARTITION} --kill-on-bad-exit=1 --exclusive --job-name=$1 -n 8 --ntasks-per-node=8 --gpus-per-task=1 python internlm/launcher/launch.py --config ./ci_scripts/train/ci_7B_sft.py
25+
srun -p ${SLURM_PARTITION} --kill-on-bad-exit=1 --exclusive --job-name=$1 -n 8 --ntasks-per-node=8 --gpus-per-task=1 python internlm/launch/launcher.py --config ./ci_scripts/train/ci_7B_sft.py
2626
[[ $? -ne 0 ]] && { echo "test slurm training failed."; exit_code=$(($exit_code + 1)); }
2727

2828
num=$(num_files "${CKPTS20_OUTPUT}")

‎ci_scripts/train/torchrun.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ if [[ -d ${CKPTS20_PATH} ]]; then
2222
fi
2323
fi
2424

25-
srun -p ${SLURM_PARTITION} --kill-on-bad-exit=1 --exclusive --job-name=$1 -N 1 torchrun --nnodes=1 --nproc_per_node=8 --master_port=29501 internlm/launcher/launch.py --config ./ci_scripts/train/ci_7B_sft.py --launcher torch
25+
srun -p ${SLURM_PARTITION} --kill-on-bad-exit=1 --exclusive --job-name=$1 -N 1 torchrun --nnodes=1 --nproc_per_node=8 --master_port=29501 internlm/launch/launcher.py --config ./ci_scripts/train/ci_7B_sft.py --launcher torch
2626
[[ $? -ne 0 ]] && { echo "test torch training failed."; exit_code=$(($exit_code + 1)); }
2727

2828
num=$(num_files "${CKPTS_OUTPUT}")

‎internlm/core/scheduler/base_scheduler.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88

99
import torch
1010

11-
from internlm.inference import InferenceParams
1211
from internlm.core.engine import Engine
12+
from internlm.inference import InferenceParams
1313

1414

1515
class BaseScheduler(ABC):

‎internlm/inference/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
from .inference_utils import InferenceParams, process_parallel_output
21
from .inference import SequenceGenerator, batch_tokenize
2+
from .inference_utils import InferenceParams, process_parallel_output
33

44
__all__ = [
55
"InferenceParams",

‎internlm/inference/inference.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44
import torch
55
import torch.nn.functional as F
66

7-
from internlm.inference import InferenceParams, process_parallel_output
87
from internlm.core.context import ParallelMode # noqa: E402
98
from internlm.core.context import global_context as gpc # noqa: E402
109
from internlm.core.trainer import Trainer
10+
from internlm.inference import InferenceParams, process_parallel_output
1111

1212

1313
class SequenceGenerator:

‎internlm/launch/launcher.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
# -*- encoding: utf-8 -*-
33

44
from internlm.core.context import global_context as gpc
5-
from internlm.launch.trainer_builder import TrainerBuilder
65
from internlm.data import (
76
build_train_loader_with_data_type,
87
build_valid_loader_with_data_type,
98
)
109
from internlm.initialize import initialize_launcher
10+
from internlm.launch.trainer_builder import TrainerBuilder
1111
from internlm.model.model_implementations.builder import create_model
1212
from internlm.model.model_implementations.registry import register_model_initializer
1313
from internlm.monitor import internevo_monitor

‎internlm/monitor/monitor.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
from datetime import datetime
21
import fcntl
32
import logging
43
import os
@@ -8,6 +7,7 @@
87
import time
98
import traceback
109
from contextlib import contextmanager
10+
from datetime import datetime
1111
from functools import wraps
1212
from threading import Thread
1313

@@ -16,7 +16,6 @@
1616
from internlm.monitor import send_feishu_msg_with_webhook
1717
from internlm.utils.common import SingletonMeta, set_env_var
1818

19-
2019
logger = logging.getLogger(__file__)
2120
internlm_accelerator = get_accelerator()
2221

0 commit comments

Comments
 (0)