Add GGUF support to T5-Encoder (#36700)
* add gguf support to t5encoder Signed-off-by: Isotr0py <2037008807@qq.com> * fix Signed-off-by: Isotr0py <2037008807@qq.com> * remove gguf from model_kwargs Signed-off-by: Isotr0py <2037008807@qq.com> --------- Signed-off-by: Isotr0py <2037008807@qq.com>
This commit is contained in:
@@ -4235,10 +4235,13 @@ class PreTrainedModel(nn.Module, ModuleUtilsMixin, GenerationMixin, PushToHubMix
|
||||
token=token,
|
||||
revision=revision,
|
||||
subfolder=subfolder,
|
||||
gguf_file=gguf_file,
|
||||
_from_auto=from_auto_class,
|
||||
_from_pipeline=from_pipeline,
|
||||
**kwargs,
|
||||
)
|
||||
if "gguf_file" in model_kwargs:
|
||||
model_kwargs.pop("gguf_file")
|
||||
else:
|
||||
# In case one passes a config to `from_pretrained` + "attn_implementation"
|
||||
# override the `_attn_implementation` attribute to `attn_implementation` of the kwargs
|
||||
|
||||
Reference in New Issue
Block a user