refactor(train): 移除未使用的模型配置参数

移除未使用的 `dtype` 和 `load_in_4bit` 变量以简化代码结构
This commit is contained in:
carry 2025-04-27 22:58:46 +08:00
parent 7a4388c928
commit 0ed43a963c

View File

@ -43,9 +43,6 @@ def train_model(
lora_rank: int,
trainer_callback=None
) -> None:
# 模型配置参数
dtype = None # 数据类型None表示自动选择
load_in_4bit = False # 使用4bit量化加载模型以节省显存
model = FastLanguageModel.get_peft_model(
# 原始模型