Skip to content

Commit dc8f284

Browse files
committed
test beam search
1 parent 2b2615a commit dc8f284

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

optimum/intel/openvino/modeling_decoder.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -559,9 +559,9 @@ def _expand_outputs_for_generation(self, indicies, logits: torch.Tensor, past_ke
559559
if indicies.shape[0] != 1:
560560
logits = logits[indicies]
561561
if past_key_values and not self.stateful:
562-
if (self.config.model_type not in MULTI_QUERY_ATTN_MODELS
563-
or (self.config.model_type == "falcon"
564-
and self.config.new_decoder_architecture)):
562+
if self.config.model_type not in MULTI_QUERY_ATTN_MODELS or (
563+
self.config.model_type == "falcon" and self.config.new_decoder_architecture
564+
):
565565
past_key_values = tuple(
566566
tuple(
567567
past_state[indicies]

tests/openvino/test_modeling.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -787,8 +787,8 @@ def test_default_filling_attention_mask_and_position_ids(self):
787787
gc.collect()
788788

789789
@parameterized.expand(SUPPORTED_ARCHITECTURES)
790-
@pytest.mark.run_slow
791-
@slow
790+
# @pytest.mark.run_slow
791+
# @slow
792792
def test_beam_search(self, model_arch):
793793
model_kwargs = {}
794794
model_id = MODEL_NAMES[model_arch]

0 commit comments

Comments
 (0)