You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
chatglm4v-9b全量微调full报错:File "/usr/local/Python3.10.0/lib/python3.10/site-packages/deepspeed/runtime/zero/stage3.py", line 149, in __init__ [rank0]: self.dtype = self.optimizer.param_groups[0]['params'][0].dtype [rank0]: IndexError: list index out of range
#2043
Closed
Sunxiaohu0406 opened this issue
Sep 14, 2024
· 1 comment
[rank0]: Traceback (most recent call last):
[rank0]: File "/home/nfs/appnfs/sxh/code/swift-latest/examples/pytorch/llm/llm_sft.py", line 6, in
[rank0]: output = sft_main()
[rank0]: File "/home/nfs/appnfs/sxh/code/swift-latest/swift/utils/run_utils.py", line 32, in x_main
[rank0]: result = llm_x(args, **kwargs)
[rank0]: File "/home/nfs/appnfs/sxh/code/swift-latest/swift/llm/sft.py", line 439, in llm_sft
[rank0]: trainer.train(training_args.resume_from_checkpoint)
[rank0]: File "/home/nfs/appnfs/sxh/code/swift-latest/swift/trainers/mixin.py", line 409, in train
[rank0]: res = super().train(resume_from_checkpoint, *args, **kwargs)
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/transformers/trainer.py", line 1948, in train
[rank0]: return inner_training_loop(
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/transformers/trainer.py", line 2105, in _inner_training_loop
[rank0]: model, self.optimizer = self.accelerator.prepare(self.model, self.optimizer)
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/accelerate/accelerator.py", line 1318, in prepare
[rank0]: result = self._prepare_deepspeed(*args)
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/accelerate/accelerator.py", line 1815, in _prepare_deepspeed
[rank0]: engine, optimizer, _, lr_scheduler = deepspeed.initialize(**kwargs)
[rank0]: File "/home/nfs/appnfs/sxh/code/swift-latest/swift/llm/utils/template.py", line 344, in _initialize
[rank0]: res = _old_initialize(*args, **kwargs)
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/deepspeed/init.py", line 176, in initialize
[rank0]: engine = DeepSpeedEngine(args=args,
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/deepspeed/runtime/engine.py", line 307, in init
[rank0]: self._configure_optimizer(optimizer, model_parameters)
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/deepspeed/runtime/engine.py", line 1257, in _configure_optimizer
[rank0]: self.optimizer = self._configure_zero_optimizer(basic_optimizer)
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/deepspeed/runtime/engine.py", line 1579, in _configure_zero_optimizer
[rank0]: optimizer = DeepSpeedZeroOptimizer_Stage3(
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/deepspeed/runtime/zero/stage3.py", line 149, in init
[rank0]: self.dtype = self.optimizer.param_groups[0]['params'][0].dtype
[rank0]: IndexError: list index out of range
The text was updated successfully, but these errors were encountered:
[rank0]: Traceback (most recent call last):
[rank0]: File "/home/nfs/appnfs/sxh/code/swift-latest/examples/pytorch/llm/llm_sft.py", line 6, in
[rank0]: output = sft_main()
[rank0]: File "/home/nfs/appnfs/sxh/code/swift-latest/swift/utils/run_utils.py", line 32, in x_main
[rank0]: result = llm_x(args, **kwargs)
[rank0]: File "/home/nfs/appnfs/sxh/code/swift-latest/swift/llm/sft.py", line 439, in llm_sft
[rank0]: trainer.train(training_args.resume_from_checkpoint)
[rank0]: File "/home/nfs/appnfs/sxh/code/swift-latest/swift/trainers/mixin.py", line 409, in train
[rank0]: res = super().train(resume_from_checkpoint, *args, **kwargs)
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/transformers/trainer.py", line 1948, in train
[rank0]: return inner_training_loop(
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/transformers/trainer.py", line 2105, in _inner_training_loop
[rank0]: model, self.optimizer = self.accelerator.prepare(self.model, self.optimizer)
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/accelerate/accelerator.py", line 1318, in prepare
[rank0]: result = self._prepare_deepspeed(*args)
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/accelerate/accelerator.py", line 1815, in _prepare_deepspeed
[rank0]: engine, optimizer, _, lr_scheduler = deepspeed.initialize(**kwargs)
[rank0]: File "/home/nfs/appnfs/sxh/code/swift-latest/swift/llm/utils/template.py", line 344, in _initialize
[rank0]: res = _old_initialize(*args, **kwargs)
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/deepspeed/init.py", line 176, in initialize
[rank0]: engine = DeepSpeedEngine(args=args,
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/deepspeed/runtime/engine.py", line 307, in init
[rank0]: self._configure_optimizer(optimizer, model_parameters)
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/deepspeed/runtime/engine.py", line 1257, in _configure_optimizer
[rank0]: self.optimizer = self._configure_zero_optimizer(basic_optimizer)
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/deepspeed/runtime/engine.py", line 1579, in _configure_zero_optimizer
[rank0]: optimizer = DeepSpeedZeroOptimizer_Stage3(
[rank0]: File "/usr/local/Python3.10.0/lib/python3.10/site-packages/deepspeed/runtime/zero/stage3.py", line 149, in init
[rank0]: self.dtype = self.optimizer.param_groups[0]['params'][0].dtype
[rank0]: IndexError: list index out of range
The text was updated successfully, but these errors were encountered: