[Question] 'Namespace' object has no attribute 'post_self_attn_layernorm'
Open
Nobody has claimed this yet.
question
- Dominant language
- Python
- Stars
- 8.5k
- Forks
- 1.3k
- Avg merge
- 5h 36m
- Merged PRs (30d)
- 22
Description
Your Question
commit hash: bd70add6ab27e773294081fd260888f003984146
slime/slime_plugins/models/glm4.py", line 11, in get_glm_spec
(pid=35379, ip=[fdbd:dccd:cdc2:12c8:0:1c3::]) post_self_attn_layernorm=args.post_self_attn_layernorm,
(pid=35379, ip=[fdbd:dccd:cdc2:12c8:0:1c3::]) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
(pid=35379, ip=[fdbd:dccd:cdc2:12c8:0:1c3::]) AttributeError: 'Namespace' object has no attribute 'post_self_attn_layernorm'
(pid=35379, ip=[fdbd:dccd:cdc2:12c8:0:1c3::]) 2026-03-02 14:16:37,933 ERROR worker.py:961 -- MEGAVISION_PREFIX: Traceback (most recent call last): File "python/ray/_raylet.pyx", line 1979, in ray._raylet.execute_task File "python/ray/_raylet.pyx", line 2087, in ray._raylet.execute_task File "python/ray/_raylet.pyx", line 1986, in ray._raylet.execute_task File "python/ray/_raylet.pyx", line 1920, in ray._raylet.execute_task.function_executor File "/opt/pyenv/versions/3.12.12/lib/python3.12/site-packages/ray/_private/function_manager.py", line 687, in actor_method_executor return method(__ray_actor, *args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/pyenv/versions/3.12.12/lib/python3.12/site-packages/ray/util/tracing/tracing_helper.py", line 463, in _resume_span return method(self, *_args, **_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/sy/slime/slime/utils/timer.py", line 97, in wrapper return fn(*args, **kwargs) ^^^^^^^^^^^^^^^^^^^ File "/sy/slime/slime/backends/megatron_utils/actor.py", line 91, in init (self.model, self.optimizer, self.opt_param_scheduler, loaded_rollout_id) = initialize_model_and_optimizer( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "sy/slime/slime/backends/megatron_utils/model.py", line 773, in initialize_model_and_optimizer model, optimizer, opt_param_scheduler = setup_model_and_optimizer(args, role) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "sy/slime/slime/backends/megatron_utils/model.py", line 108, in setup_model_and_optimizer model = get_model( ^^^^^^^^^^ File "/opt/tiger/Megatron-LM/megatron/training/training.py", line 997, in get_model model = build_model() ^^^^^^^^^^^^^ File "/opt/tiger/Megatron-LM/megatron/training/training.py", line 989, in build_model model = model_provider_func(pre_process=pre_process, post_process=post_process) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/slime/slime/backends/megatron_utils/model_provider.py", line 215, in wrapped_provider model = original_provider(pre_process=pre_process, post_process=post_process, vp_stage=vp_stage) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/slime/slime/backends/megatron_utils/model_provider.py", line 123, in model_provider transformer_layer_spec = transformer_layer_spec(args, config, vp_stage) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "slime/slime_plugins/models/glm4.py", line 11, in get_glm_spec post_self_attn_layernorm=args.post_self_attn_layernorm, ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AttributeError: 'Namespace' object has no attribute 'post_self_attn_layernorm'
What I've Tried
- I read the Quick start and follow the guide
- since the ray is running in company paltform, and run ray job submit directly and not kill and start
Environment (if relevant)
- slime version:bd70add6ab27e773294081fd260888f003984146
- Python version: 3.12.12
- PyTorch version:2.91
- CUDA/ROCm version:2.9.1+cu129
- GPU type and count:H100 8
- OS:Linux n124-105-135 5.15.120.bsk.6-amd64 #5.15.120.bsk.6 SMP Debian 5.15.120.bsk.6 Fri Apr 19 02:51:48 UT x86_64 GNU/Linux
Additional Context
No response
Pre-submission Checklist
- I have read the CONTRIBUTING.md and understand the collaboration scope.
- I have read the documentation and FAQ and my question is not answered there.
- I have searched for existing issues and my question has not been asked before.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at slime/slime_plugins/models/glm4.py in get_glm_spec, then trace how the Namespace is built through slime/backends/megatron_utils/model_provider.py and the model setup path. Reproduce the reported failure at commit bd70add6ab27e773294081fd260888f003984146 and determine how the missing argument is expected to be supplied. Done means GLM4 model initialization reaches completion without this AttributeError.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python, pytorch
- Domain
- machine-learning
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100