Skip to content

Commit

Permalink
pass config when convert class
Browse files Browse the repository at this point in the history
Signed-off-by: jiqing-feng <[email protected]>
  • Loading branch information
jiqing-feng committed Dec 18, 2024
1 parent b0cec9c commit 0c80be3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions optimum/exporters/ipex/model_patcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ def _patch_bert_model(model):
Patch bert model:
1. Linear fusion with Linear + Gelu
"""
convert_class(model, BertIntermediate, _IPEXIntermediate)
convert_class(model, BertIntermediate, _IPEXIntermediate, model.config)
return model


Expand All @@ -128,7 +128,7 @@ def _patch_vit_model(model):
Patch vit model:
1. Linear fusion with Linear + Gelu
"""
convert_class(model, ViTIntermediate, _IPEXIntermediate)
convert_class(model, ViTIntermediate, _IPEXIntermediate, model.config)
return model


Expand Down

0 comments on commit 0c80be3

Please sign in to comment.