Fix gemma 3 launch with transformers: the error: AttributeError: 'TransformersForCausalLM' object has no attribute 'tp_size' (#9614)
This commit is contained in:
1 parent
24f7cb1ece
commit
71959545df
1 file changed
-2
@@ -20,7 +20,6 @@ import torch.nn.functional as F
|
|||||||
from torch import nn
|
from torch import nn
|
||||||
from transformers import (
|
from transformers import (
|
||||||
ROPE_INIT_FUNCTIONS,
|
ROPE_INIT_FUNCTIONS,
|
||||||
AutoModel,
|
|
||||||
Gemma3TextConfig,
|
Gemma3TextConfig,
|
||||||
PretrainedConfig,
|
PretrainedConfig,
|
||||||
PreTrainedModel,
|
PreTrainedModel,
|
||||||
@@ -761,4 +760,3 @@ class Gemma3ForCausalLM(PreTrainedModel):
|
|||||||
|
|
||||||
|
|
||||||
EntryClass = Gemma3ForCausalLM
|
EntryClass = Gemma3ForCausalLM
|
||||||
AutoModel.register(Gemma3TextConfig, Gemma3ForCausalLM, exist_ok=True)
|
|
||||||
Reference in new issue
Block a user