reafactor: 统一并增强项目中的工厂模式实现

This commit is contained in:
2026-03-30 01:33:14 +08:00
parent 60f4df95bd
commit 3e33c14376
9 changed files with 550 additions and 157 deletions
+2 -2
View File
@@ -134,8 +134,8 @@ def spawn_parallel_fn(
if world_size == 1:
device_ids = device_ids or [0]
deice_id = torch.device(device_type, device_ids[0])
os.environ["LOCAL_DEVICE"] = str(deice_id)
device_id = torch.device(device_type, device_ids[0])
os.environ["LOCAL_DEVICE"] = str(device_id)
func(**kwargs)
return