Skip to content

Commit 1357b87

Browse files
fix ipex
1 parent d47a368 commit 1357b87

5 files changed

Lines changed: 1 addition & 9 deletions

File tree

examples/cpu_ipex_bert.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ launcher:
1616

1717
backend:
1818
device: cpu
19-
export: true
2019
no_weights: false # on multi-node machines, inline weights initialization harms performance
2120
torch_dtype: float32 # use bfloat16 on compatible Intel CPUs
2221
model: google-bert/bert-base-uncased

examples/cpu_ipex_llama.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ launcher:
1616

1717
backend:
1818
device: cpu
19-
export: true
2019
no_weights: false # on multi-node machines, intializing weights in the benchmark could harm performance
2120
torch_dtype: float32 # use bfloat16 on compatible Intel CPUs
2221
model: TinyLlama/TinyLlama-1.1B-Chat-v1.0

optimum_benchmark/backends/ipex/backend.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -55,18 +55,13 @@ def load_ipexmodel_from_pretrained(self) -> None:
5555
def load_ipexmodel_with_no_weights(self) -> None:
5656
with fast_weights_init():
5757
original_model, self.config.model = self.config.model, self.no_weights_model_path.as_posix()
58-
original_export, self.config.export = self.config.export, True
5958
self.load_ipexmodel_from_pretrained()
60-
self.config.export = original_export
6159
self.config.model = original_model
6260

6361
@property
6462
def ipexmodel_kwargs(self) -> Dict[str, Any]:
6563
kwargs = {}
6664

67-
if self.config.export:
68-
kwargs["export"] = self.config.export
69-
7065
if self.config.torch_dtype is not None:
7166
kwargs["torch_dtype"] = getattr(torch, self.config.torch_dtype)
7267

optimum_benchmark/backends/ipex/config.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ class IPEXConfig(BackendConfig):
1616
no_weights: bool = False
1717

1818
# ipexmodel kwargs
19-
export: Optional[bool] = None
2019
torch_dtype: Optional[str] = None
2120

2221
def __post_init__(self):

tests/test_examples.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ def test_cli_configs(config_name):
5959
"--config-name",
6060
config_name,
6161
"scenario.warmup_runs=1",
62-
"scenario.input_shapes.batch_size=2",
62+
"scenario.input_shapes.batch_size=1",
6363
"++scenario.input_shapes.sequence_length=16",
6464
"++scenario.generate_kwargs.max_new_tokens=16",
6565
"++scenario.generate_kwargs.min_new_tokens=16",

0 commit comments

Comments
 (0)